Subject Re: [IB-Architect] Re: 32-bit integers
Author Charlie Caro
Dmitry Kuzmenko wrote:
>
> Hello, All!
>
> I'm apologizing about this really stupid message.
> I was mistaken with the numeric tests, and saw wrong results.
> Had a bad, bad day...
>

Couldn't be worse than my last three weeks.

> Of course, INTEGER is still 32-bit in dialect 3.
> The only thing I don't understand is why INT64 datatype
> can't be used directly, but only via NUMECIC(18) (or like this).
> Can somebody explain why?
>

The feature was developed with SQL compliance in mind. Although the SQL standard
defines a SMALLINT and INTEGER, it does not define a keyword of INT64 or
LARGEINT (although some vendors do so). The INT64 data type is defined in
ibase.h for language binding purposes as well as SQL_INT64 to support a
statement describe for your storage allocation purposes.

The SQL standard as well as the InterBase architects(s) would prefer that you
design your applications with the exact precision and scale in mind rather than
ascribing underlying implementation details to certain keywords. It aids
application portability.

That said, it's trivial to add keyword synonyms and noise words to the InterBase
parser.

Regards,
Charlie