Subject Re: [firebird-support] Firebird Errors
Author Helen Borrie
At 01:45 PM 26/02/2004 +0200, you wrote:
>Hi,
>
>What's the difference and why we need both SQLCODE and "Interbase
>Number" when firebird is reporting errors.
>
>The term "Interbase Number" is taken from the IB6.0 language reference.
>Maybe it must be
>"Firebird Number" now :))

Actually, it's GDSCODE. (GDS=Groton Database Systems, the name of Jim and
Ann's company when they first developed InterBase). It's called "InterBase
Number" in the Borl docs, which is confusing, since PSQL implements
detection of it as "GDSCODE". Firebird 1.5 even gives it to you as a
context variable, inside a WHEN block.

Did you happen to know that you can use a constant in lieu of the
gdscode? Just strip the "isc_" prefix off the front of the constant
defined in iberror.h (in you /include directory) and you have a nice,
meaningful error code constant. :-))

/heLen