Re: problem using twice custom comparision operator - Mailing list pgsql-sql

From Tom Lane
Subject Re: problem using twice custom comparision operator
Date
Msg-id 23403.1232750452@sss.pgh.pa.us
Whole thread Raw
In response to problem using twice custom comparision operator  (Marek Florianczyk <franki@adm.tp.pl>)
List pgsql-sql
Marek Florianczyk <franki@adm.tp.pl> writes:
> Hi all,
> I wanted to make custom operator to sort data like this:
> 1,2,10,1a,1b,10a

It might work better if you were more careful to ensure that the
operator were a valid sort operator, ie
! a<a            not reflexivea < b => ! b < a    not commutativea < b & b < c => a < c    transitive

It fairly obviously fails the first of these, and I don't have too much
confidence in the others.
        regards, tom lane


pgsql-sql by date:

Previous
From: Marek Florianczyk
Date:
Subject: problem using twice custom comparision operator
Next
From: Steve Midgley
Date:
Subject: Re: problem using twice custom comparision operator