Re: Unary Operators - Mailing list pgsql-general

From David Johnston
Subject Re: Unary Operators
Date
Msg-id 1379463464599-5771360.post@n5.nabble.com
Whole thread Raw
In response to Re: Unary Operators  (Rowan Collins <rowan.collins@gmail.com>)
Responses Re: Unary Operators  (Andreas Ulbrich <andreas.ulbrich@matheversum.de>)
List pgsql-general
Andreas Ulbrich wrote
> create operator ^- (leftarg = float, procedure = reciproce);
> works too, but
> create operator / (leftarg = float, procedure = reciproce);
> not.

Do you mean the "^" operator or the "^-" operator?  Rowan claims that "^"
does not in fact work here...


Rowan Collins wrote
> I've tried ^ and *
> and get the same error (you need some extra brackets around "SELECT (*
> 5.0)" otherwise it would look like "SELECT *", which is an entirely
> different piece of syntax!).

I would tend to concur with the "hard-wired" theory but am in the same boat
that I'm not really able to prove so; but figured I'd give my support.

This qualifies as documentation improvement potential at minimum so in the
interest of getting more notice I'd suggest reconciling the "^" discrepancy
- and maybe trying the other supposedly hybrid operators and stating which
ones work and don't work for the report - and move this over there.

David J.




--
View this message in context: http://postgresql.1045698.n5.nabble.com/Unary-Operators-tp5770983p5771360.html
Sent from the PostgreSQL - general mailing list archive at Nabble.com.


pgsql-general by date:

Previous
From: David Johnston
Date:
Subject: Re: Why does this array query fail?
Next
From: Ken Tanzer
Date:
Subject: Re: Why does this array query fail?