Re: Accent-insensitive - Mailing list pgsql-sql

From Joel Burton
Subject Re: Accent-insensitive
Date
Msg-id 20021207211948.GA5760@temp.joelburton.com
Whole thread Raw
In response to Accent-insensitive  ("Pedro Igor" <pedroigor@aip.com.br>)
List pgsql-sql
On Sat, Dec 07, 2002 at 07:06:45PM -0300, Pedro Igor wrote:
> Thanks, you know if some possible release would have some internal to deal
> with this ?
> 
> Abraços
> Pedro Igor
> >
> > CREATE FUNCTION lower_ascii (text) RETURNS text AS '
> >   BEGIN
> >     RETURN lower(to_ascii($1));
> >   END
> > ' language 'plpgsql';
> >
> > CREATE INDEX table_lower_ascii ON table(lower_ascii(field));

Pedro --

Please keep conversations on the list -- other people may know things I
don't (actually, they certainly will!), and it allows other people to
follow the conversation.

As for this being internal, I have no idea -- you could submit it as a
suggestion.

Given how easy it is to implement in plpgsql, I suspect this kind of thing will
stay out of the internals. Keep in mind that if you define this function
in your template1 database, you can have it created automatically in all
new databases you create, so it's one less thing to worry about.

HTH.

-- 

Joel BURTON  |  joel@joelburton.com  |  joelburton.com  |  aim: wjoelburton
Independent Knowledge Management Consultant


pgsql-sql by date:

Previous
From: "D'Arcy J.M. Cain"
Date:
Subject: Re: SELECT FOR UPDATE locks whole table
Next
From: "Dan Langille"
Date:
Subject: adding a GROUP BY to an outer join