From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Andres Freund <andres(at)2ndquadrant(dot)com> |
Cc: | Merlin Moncure <mmoncure(at)gmail(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: operator precedence issues |
Date: | 2013-09-03 14:13:12 |
Message-ID: | 15949.1378217592@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Andres Freund <andres(at)2ndquadrant(dot)com> writes:
> On 2013-09-03 08:59:53 -0500, Merlin Moncure wrote:
>> While playing around with Andres's trick, I noticed that it works but
>> will not match against operators taking "any" although those will
>> match with explicit schema declaration (FWICT it goes through the
>> search_path trying to explicitly match int/int operator then goes
>> again matches "any"). That's pretty weird:
> Not surprising. We look for the best match for an operator and
> explicitly matching types will be that. If there were no operator(int,
> int) your anyelement variant should get called.
Yeah, this has exactly nothing to do with operator precedence.
Precedence is about which operator binds tighter in cases like "A+B*C".
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Blake Smith | 2013-09-03 14:24:07 | Re: Hstore: Query speedups with Gin index |
Previous Message | Andres Freund | 2013-09-03 14:05:32 | Re: operator precedence issues |