Re: Full text index without accents

From: "Jonathan Bond-Caron" <jbondc(at)gmail(dot)com>
To: "'Tom Lane'" <tgl(at)sss(dot)pgh(dot)pa(dot)us>, "'Alvaro Herrera'" <alvherre(at)commandprompt(dot)com>
Cc: 'Fco(dot) Mario Barcala Rodríguez' <lbarcala(at)freeresearch(dot)org>, <pgsql-general(at)postgresql(dot)org>
Subject: Re: Full text index without accents
Date: 2008-07-25 15:06:38
Message-ID: 000301c8ee68$0be86c10$23b94430$@com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Ya the function name norm_text_latin() was probably misleading, it takes
latin1-ish characters *encoded in UTF8* and brings them to ascii.

Definitely, the following would be much simpler:
SELECT to_ascii('ÀÁÂÃÄÅÒÓÔÕÖ', 'UTF8')

As of 8.3, you have to do some magic with to_ascii() and utf8 characters

SELECT to_ascii(convert_to_latin('ÀÁÂÃÄÅÒÓÔÕÖ'), 'LATIN1')

-----Original Message-----
From: pgsql-general-owner(at)postgresql(dot)org
[mailto:pgsql-general-owner(at)postgresql(dot)org] On Behalf Of Tom Lane
Sent: July 25, 2008 10:42 AM
To: Alvaro Herrera
Cc: Jonathan Bond-Caron; 'Fco. Mario Barcala Rodríguez';
pgsql-general(at)postgresql(dot)org
Subject: Re: [GENERAL] Full text index without accents

Alvaro Herrera <alvherre(at)commandprompt(dot)com> writes:
> Hmm, why not simply use to_ascii() ?

The big problem with to_ascii is its inadequate set of supported
encodings. Somebody *really* needs to give it some love on that
front.

regards, tom lane

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Tino Wildenhain 2008-07-25 15:40:37 Re: php + postgresql
Previous Message admin 2008-07-25 14:56:54 Re: Data base tables design questions for: user saved forms, user parameters