Re: self defined data type "with limit"?

From: Michael Enke <michael(dot)enke(at)wincor-nixdorf(dot)com>
To: pgsql-hackers(at)postgresql(dot)org
Subject: Re: self defined data type "with limit"?
Date: 2007-06-28 08:48:30
Message-ID: 468375DE.1070305@wincor-nixdorf.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Heikki Linnakangas wrote:
> Michael Enke wrote:
>
>> My primary goal is to get quasi numeric ordering on text column, e.g.
>> 1
>> 2
>> 10
>> Normal order with varchar would be
>> 1
>> 10
>> 2
>
>
> You don't need to custom type for that. A custom operator class with
> custom comparison operators is enough.
>

Ok, I tried with ordinary varchar and my own operators/op class. But than:
1) the index is never used (I created it 'with' my opclass)
2) the 'order by' doesn't care about my operator class, it's normal varchar sequence.

Regards,
Michael

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce McAlister 2007-06-28 09:33:58 Re: AutoVacuum Behaviour Question
Previous Message Martijn van Oosterhout 2007-06-28 08:07:42 Re: AutoVacuum Behaviour Question