Informix Error -1271: Missing decimal point in datetime or interval fraction.
Cause and resolution
Missing decimal point in datetime or interval fraction.
A decimal point is expected to appear in a DATETIME or INTERVAL literal when the qualifier of the literal contains the word FRACTION. This statement has such a literal, but no decimal point was found. Inspect the literal qualifiers for missing or misplaced punctuation.
Oninit® Troubleshooting Guidance
Reasons / Common Causes
-1271 fires when a DATETIME/INTERVAL literal's qualifier includes FRACTION, but the
literal itself has no decimal point — per the official guidance, FRACTION in the qualifier
requires a corresponding decimal point in the literal.
- A
FRACTIONqualifier used without a decimal point in the literal, per the official guidance — the direct, only cause.
Solutions / Resolution
- Inspect the literal qualifiers for missing or misplaced punctuation, per the official
guidance — add the decimal point the
FRACTIONqualifier requires.
Examples
A FRACTION qualifier without a decimal point
SELECT DATETIME(10:30:00) HOUR TO FRACTION(3) FROM orders WHERE order_id = 1;
-- -1271: FRACTION requires a decimal point in the literal
Corrected
SELECT DATETIME(10:30:00.123) HOUR TO FRACTION(3) FROM orders WHERE order_id = 1;
Diagnostic Checks
- Check whether the qualifier includes
FRACTION, and confirm the literal has a corresponding decimal point.
Related Errors / Related Topics
- -1268 — "Invalid datetime or interval qualifier." A related qualifier error, about the qualifier's keywords themselves being invalid rather than a missing decimal point.
FRACTION in the qualifier requires a decimal point in the literal — add the missing decimal
point.