Re: order by, for custom types

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Grzegorz Jaskiewicz <gj(at)pointblue(dot)com(dot)pl>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: order by, for custom types
Date: 2005-11-18 21:53:11
Message-ID: 8965.1132350791@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Grzegorz Jaskiewicz <gj(at)pointblue(dot)com(dot)pl> writes:
> I have all operators required for b-tree, gist up here, and gist
> index defined. But still "order by custom_type" won't work.

Define "won't work" ... what happens?

> I have kind of wild card masks in my type definition, so b-tree won't
> work. But still, do I need to define b-tree index as such for "order
> by" to work ?

You don't need an index, but a b-tree operator class is a good idea.
Still, it should be possible to sort with only a "<" operator --- at
the moment anyway. (I've been thinking about some ideas that would
effectively require a b-tree opclass to do sorting, so this might not
still be true in 8.2 ...)

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Jonah H. Harris 2005-11-18 22:29:48 Re: PCTFree Results
Previous Message Joshua D. Drake 2005-11-18 21:07:41 Re: Bug in predicate indexes?