Re: [SQL] numeric when compared to literal

2003-02-06 Thread Tom Lane
Vicente Alabau Gonzalvo <[EMAIL PROTECTED]> writes: > db=> select * from tipos where _numeric_ <= 2147483648; > ERROR: Unable to identify an operator '<=' for types 'numeric' and > 'double precision' 7.3 is more forgiving about this (although there's no free lunch --- some other cases are now le

[SQL] numeric when compared to literal

2003-02-06 Thread Vicente Alabau Gonzalvo
When a numeric is compared to a literal < 2^31 - 1 it works well, but compared to a greater literal, it is casted to double precision. Why? How can I correct this without explicit cast? db=> \d tipos Table "tipos" Column | Type | Modifiers ---+-+--- _nume