Adrian Klaver <adrian.kla...@aklaver.com> writes: > On 09/17/2015 06:54 AM, Tom Lane wrote: >> Well, that's true: the parser actually looks up the operator named "<>" >> for the given data types, and IS DISTINCT FROM is just a prefilter on >> that to do the right thing with nulls. So because type point has an >> operator that's physically named "<>", that case works.
> If you use '<>' explicitly, otherwise: > test=> select '(1,2)'::point is distinct from '(1,3)'::point; > ERROR: operator does not exist: point = point Ah, sorry, actually what IS [NOT] DISTINCT FROM looks up is the "=" operator. The core point remains, though, that this is a name-based lookup rather than an opclass-based one. I'd like to get us moved over to using opclass-based lookups for all cases where the system currently assumes that operators named "=" or "<>" necessarily behave in a particular way. However, that would leave point and some of the other weirder datatypes even further out in the cold than they are now. regards, tom lane -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general