Informix Error -572
-572 The specified wait duration is too long.
The maximum time that you can specify as the WAIT time in SET LOCK MODE is 32,767 seconds. Review this statement, and make sure it specifies the duration in seconds that you intended. If so, either use a shorter duration, or (since 32,767 seconds is more than 9 hours) simply omit the duration to specify an indefinite wait.
Oninit® Troubleshooting Guidance
Reasons / Common Causes
-572 is a hard ceiling on SET LOCK MODE TO WAIT <seconds>: the maximum wait duration that can be
specified is 32,767 seconds (just over 9 hours), per the official guidance, and a value above
that is rejected.
- A wait duration specified in the wrong unit — for example, intending minutes or a larger unit but writing the number as if it were seconds, producing a value far past the limit.
- A deliberately very long duration chosen to approximate "wait indefinitely", without realizing an indefinite wait is available directly by omitting the duration.
- A generated/templated configuration value exceeding the limit due to a unit-conversion bug elsewhere in the code that builds the statement.
Solutions / Resolution
- Review the statement and confirm the intended duration in seconds, per the official guidance — check for a unit mistake first.
- Use a shorter duration if a bounded wait was genuinely intended and the value was simply too large.
- Omit the duration entirely for an indefinite wait, per the official guidance — since 32,767 seconds is already more than 9 hours, omitting the duration is the documented way to wait longer than that (or indefinitely) rather than trying to specify a larger number.
Examples
Exceeding the limit
SET LOCK MODE TO WAIT 100000;
-- -572: exceeds the 32,767-second maximum
A bounded wait within the limit
SET LOCK MODE TO WAIT 60;
An indefinite wait
SET LOCK MODE TO WAIT;
Diagnostic Checks
- Check the numeric value passed to
WAITagainst the 32,767-second ceiling, and confirm it's actually expressed in seconds as intended.
Related Errors / Related Topics
- -527 — "Lock Mode is not available on this system." A related
SET LOCK MODEerror, about the WAIT mode not being supported at all on certain platforms rather than a duration exceeding the limit.
A 32,767-second (about 9 hours) ceiling on WAIT <seconds> — omit the duration for an
indefinite wait instead of specifying a larger number.