Thanks to visit codestin.com
Credit goes to postgrespro.com

Re: Accent-insensitive - Mailing list pgsql-sql

From Cédric Dufour (public)
Subject Re: Accent-insensitive
Date
Msg-id [email protected]
Whole thread Raw
In response to Accent-insensitive  ("Pedro Igor" <[email protected]>)
Responses Re: Accent-insensitive
List pgsql-sql
Use the 'to_ascii' function to convert your string to the "no accent" ASCII equivalent before accomplishing your comparison
 
SELECT foo FROM table WHERE ( to_ascii(foo) ILIKE to_ascii('caractères accentués') );
 
This does not work with all database locale (LATIN1 is OK, but LATIN9 is not).
 
I was actually wondering if this is efficient enough or if there is any more efficient method to accomplish this...
 
    Cédric D.
-----Original Message-----
From: [email protected] [mailto:[email protected]]On Behalf Of Pedro Igor
Sent: Friday, December 06, 2002 14:31
To: [email protected]
Subject: [SQL] Accent-insensitive

Does have PostgreSQL some option to allow me execute selects accent-insensitive ?
I can´t find any reference, including the manual ....
 
Pedro Igor

pgsql-sql by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: SELECT FOR UPDATE locks whole table
Next
From: Joel Burton
Date:
Subject: Re: Accent-insensitive