Re: COMMUTATOR doesn't seem to work

From: D'Arcy Cain <darcy(at)druid(dot)net>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: COMMUTATOR doesn't seem to work
Date: 2012-06-22 04:32:35
Message-ID: 4FE3F563.10504@druid.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 12-06-22 12:22 AM, Tom Lane wrote:
> Um, an operator with different types on left and right cannot be its own
> commutator.

Understood. I completely misunderstood the purpose of COMMUTATOR. I
thought that it was telling the system that the procedure could be
called with the arguments reversed if it could not find a specific
procedure. I see now what it is for.

So I have my type working now but I had to create a new C function
that take the opposite argument order. Seems redundant but I could
not see a better way.

--
D'Arcy J.M. Cain <darcy(at)druid(dot)net> | Democracy is three wolves
http://www.druid.net/darcy/ | and a sheep voting on
+1 416 425 1212 (DoD#0082) (eNTP) | what's for dinner.
IM: darcy(at)Vex(dot)Net

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Kyotaro HORIGUCHI 2012-06-22 06:31:39 Re: pl/perl and utf-8 in sql_ascii databases
Previous Message Tom Lane 2012-06-22 04:22:07 Re: COMMUTATOR doesn't seem to work