Informix Error -4646: The specified WORDWRAP RIGHT MARGIN value is out of range. It must be greater than or equal to the current column and less than or equal to the report's right margin.
Cause and resolution
The specified WORDWRAP RIGHT MARGIN value is out of range. It must be greater than or equal to the current column and less than or equal to the report's right margin.
Modify this PRINT statement to specify a right margin for the WORDWRAP function that does not exceed the report right margin. The report right margin is set in the OUTPUT section of the report.
Oninit® Troubleshooting Guidance
Reasons / Common Causes
-4646 fires when a PRINT statement's WORDWRAP right-margin value falls outside the valid
range — per the official guidance, it must be at least the current column and at most the
report's right margin, which is set in the report's OUTPUT section.
- A
WORDWRAPright-margin value less than the current column, per the official guidance — the first named case. - A
WORDWRAPright-margin value greater than the report's right margin, per the official guidance — the second named case.
Solutions / Resolution
- Modify the
PRINTstatement'sWORDWRAPright-margin value, per the official guidance, so it stays within the current-column-to-report-right-margin range.
Examples
An out-of-range WORDWRAP margin
OUTPUT
RIGHT MARGIN 80
...
PRINT COLUMN 10, notes WORDWRAP RIGHT MARGIN 90
-- -4646: 90 exceeds the report's right margin of 80
Corrected
PRINT COLUMN 10, notes WORDWRAP RIGHT MARGIN 80
Diagnostic Checks
- Check the report's right margin (set in
OUTPUT), and confirm everyWORDWRAPright margin value stays between the current column and that value.
Related Errors / Related Topics
- -4486 — "TEXT or BYTE variables and wordwrap fields cannot be printed in report headers or trailers." A related wordwrap restriction, about header/trailer placement rather than the margin value's range.
A WORDWRAP right-margin value is outside the valid range — keep it between the current
column and the report's right margin.