The dot is not an operator, it is the decimal separator. This is SQL standard syntax for an exact numeric literal, and Firebird follows that syntax here. Quoting from the ISO/IEC 9075-2:2016 ("the SQL standard"):
<exact numeric literal> ::=
<unsigned integer> [ <period> [ <unsigned integer> ] ]
| <period> <unsigned integer>
This production rule makes 3.
as valid as 3
. In other words, it allows you to specify the decimal dot without specifying any digits after the dot. This is also not specific to Firebird, most if not all SQL implementations apply this syntax rule.
This is also specified in the section Number literals of the chapter Common Language Elements in the Firebird 3.0 Language Reference:
Format |
Type |
... |
... |
<d>[<d> …] "." [<d> …] |
NUMERIC(18, n) where n depends on the number of digits after the decimal point |
The difference is that in Firebird the literal 3
is typed as an INTEGER
, while 3.
is typed as a BIGINT
(or NUMERIC(18, 0)
).