Re: [BUGS] Casting on the limit

2008-01-21 Thread Ottó Havasvölgyi
Thank you:) I didn't even thought of this case. I am a bit surprised that "::" has higher precedence than negation, but maybe it has some cause. Sorry for sending it to this list. Best regards, Otto 2008/1/21, Heikki Linnakangas <[EMAIL PROTECTED]>: > Ottó Havasvölgyi wrote: > > In 8.2.5: > > >

Re: [BUGS] Casting on the limit

2008-01-21 Thread Heikki Linnakangas
Ottó Havasvölgyi wrote: In 8.2.5: This does not work (out of range): select -32768::int2 But this works: select cast(-32768 as int2); What is the difference between the two syntax in the background? I always thought they are the same. "select -32768::int2" is equal to "select -(32768::int2)"

Re: [BUGS] Casting on the limit

2008-01-21 Thread Ottó Havasvölgyi
But 8.2.6 works the same. I have just upgraded. 2008/1/21, Ottó Havasvölgyi <[EMAIL PROTECTED]>: > Sorry, version is 8.2.4 > > 2008/1/21, Ottó Havasvölgyi <[EMAIL PROTECTED]>: > > Hi, > > > > In 8.2.5: > > > > This does not work (out of range): > > select -32768::int2 > > > > But this works: > > s

Re: [BUGS] Casting on the limit

2008-01-21 Thread Ottó Havasvölgyi
Sorry, version is 8.2.4 2008/1/21, Ottó Havasvölgyi <[EMAIL PROTECTED]>: > Hi, > > In 8.2.5: > > This does not work (out of range): > select -32768::int2 > > But this works: > select cast(-32768 as int2); > > What is the difference between the two syntax in the background? I > always thought they

[BUGS] Casting on the limit

2008-01-21 Thread Ottó Havasvölgyi
Hi, In 8.2.5: This does not work (out of range): select -32768::int2 But this works: select cast(-32768 as int2); What is the difference between the two syntax in the background? I always thought they are the same. Best regards, Otto ---(end of broadcast)--