Re: starne error from select 1!=-1

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Andrus" <eetasoft(at)online(dot)ee>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: starne error from select 1!=-1
Date: 2006-04-15 21:00:31
Message-ID: 10145.1145134831@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

"Andrus" <eetasoft(at)online(dot)ee> writes:
> select 1!=-1
> ERROR: operator does not exist: integer !=- integer

> Isn't this a bit stange ?

No. We couldn't really parse this any other way without disallowing -
(and +) altogether in multi-character operator names. There's a special
hack for SQL-spec compatibility, but it doesn't trigger in this case;
see

http://www.postgresql.org/docs/8.1/static/sql-syntax.html#SQL-SYNTAX-OPERATORS

regards, tom lane

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Francisco Reyes 2006-04-15 22:35:06 Re: Hardware related question: 3ware 9500S
Previous Message Andrus 2006-04-15 20:41:33 starne error from select 1!=-1