[Info-ingres] When is an empty string an integer?
Karl Schendel
schendel at kbcomputer.com
Wed May 11 13:53:47 UTC 2016
On May 11, 2016, at 9:44 AM, Roy Hann <specially at processed.almost.meat> wrote:
>
> Martin Bowes wrote:
>
>> FYI. Geraint Jones has informed me that:
>> Various DBMS's disagree on how to handle cast('' as integer).
>>
>> Ingres : 0.
>> Oracle : NULL.
>> Postgres : Error.
>
> Oracle, wrong as usual--but not as wrong as Ingres on this occasion!
>
> Postgres gets my nod on this one.
>
> Roy
>
> PS: I wonder if Ingres' alignment with MySQL's foolishness is just
> accidental? I do hope so.
Yes, I'm sure it is. The relevant CVal routine in the CL does nothing if
it sees no digits, and returns OK. I'm sure it's been that way since forever.
Karl
More information about the Info-ingres
mailing list