Re: Allowing extensions to supply operator-/function-specific info - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Allowing extensions to supply operator-/function-specific info
Date
Msg-id 26156.1551734021@sss.pgh.pa.us
Whole thread Raw
In response to Re: Allowing extensions to supply operator-/function-specific info  (Paul Ramsey <pramsey@cleverelephant.ca>)
Responses Re: Allowing extensions to supply operator-/function-specific info
List pgsql-hackers
Paul Ramsey <pramsey@cleverelephant.ca> writes:
> I had what seemed to be working code except for a couple rare cases,
> but when I fixed those cases it turned out that I had a major problem:
> building a <var> OP <const> expression works fine, but building a
> <const> OP <var> expression returns me an error.

Yup, you're not supposed to do that.  The output expression *must* have
the index key on the left, it's up to you to commute the operator if
needed to make that happen.

            regards, tom lane


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Rare SSL failures on eelpout
Next
From: Peter Geoghegan
Date:
Subject: Re: Making all nbtree entries unique by having heap TIDs participatein comparisons