Informix Error -804: Comment has no end.
Cause and resolution
Comment has no end.
This statement includes a comment that is enclosed in braces ({ }), but the closing brace is missing. Review the punctuation of the statement, and check that all braces appear in matching pairs.
Oninit® Troubleshooting Guidance
Reasons / Common Causes
-804 fires when a brace-delimited comment ({ ... }) is missing its closing brace — per the
official guidance, every opening brace needs a matching closing one.
- A missing closing
}, per the official guidance — the direct, only cause. - A brace character appearing inside the comment's own text (unbalanced on purpose or by accident), confusing the count of matched pairs.
- A comment spanning multiple lines where the closing brace was accidentally deleted during editing, leaving everything after it absorbed into the unterminated comment.
Solutions / Resolution
- Review the punctuation of the statement and check that all braces appear in matching pairs, per the official guidance.
- Count opening and closing braces in the statement, especially in long or multi-line comments, to find the specific unmatched one.
Examples
The disallowed unterminated comment
SELECT * FROM orders { this comment is missing its closing brace
WHERE status = 'pending';
-- -804: no closing } found
Corrected
SELECT * FROM orders { this comment now closes properly }
WHERE status = 'pending';
Diagnostic Checks
- Scan the statement for every
{and confirm each has a matching}.
Related Errors / Related Topics
No closely related error codes are cross-referenced for -804 in this set yet.
A straightforward unmatched brace in a comment — count opening and closing braces to find the missing one.