Informix Error -4373: A grammatical error has been found on line line-number, character char-number. The construct is not understandable in its context.
Cause and resolution
A grammatical error has been found on line line-number, character char-number. The construct is not understandable in its context.
This general message shows an inability to parse a 4GL statement. The line and character numbers show the point at which the parser detected a problem. However, this is almost never the point at which the error exists. Start there, and work backward in the program looking for other error messages and for missing punctuation, missing END statements, and other mistakes. If the statement at line-number is END FUNCTION, END MAIN, or END REPORT, one probable cause is the absence of another END, possibly many lines earlier. Usually a missing END IF is the culprit. If the cause for this error is not obvious, concentrate on eliminating any other, more specific error messages, and this one will probably go away also.
Oninit® Troubleshooting Guidance
Reasons / Common Causes
-4373 is a general parse-failure message — per the official guidance, the reported line/
character is almost never where the actual error exists; work backward from there looking for
missing punctuation and missing END statements. If the reported line is END FUNCTION,
END MAIN, or END REPORT, the likely cause is a missing END somewhere earlier — often a
missing END IF.
- A syntax mistake somewhere before the reported line/character, per the official
guidance — often a missing
END IFor other missingENDstatement.
Solutions / Resolution
- Start at the reported point and work backward, per the official guidance, looking for
other error messages, missing punctuation, and missing
ENDstatements. - If the reported line is
END FUNCTION/END MAIN/END REPORT, look for a missingENDearlier in the code, per the official guidance. - If the cause isn't obvious, fix any other more specific error messages first, per the official guidance — this one often disappears once those are fixed.
Examples
A missing END IF causing a downstream parse failure
IF status = "New" THEN
CALL initialize()
-- missing END IF here causes a later construct to be unparseable
END FUNCTION
Corrected
IF status = "New" THEN
CALL initialize()
END IF
END FUNCTION
Diagnostic Checks
- Work backward from the reported line/character, checking for missing
ENDstatements and punctuation, and fix any other specific errors first.
Related Errors / Related Topics
- -4144 — "A grammatical error has been found in an INCLUDEd file. The construct is not
understandable in its context." A closely related parse-failure error, specific to code
reached via
INCLUDErather than the main source file.
A grammatical error was reported at a line/character — work backward from there, since the
real cause (often a missing END) is usually earlier.