Re: UTF-8 to ASCII

From: "Albe Laurenz" <all(at)adv(dot)magwien(dot)gv(dot)at>
To: "Martin Marques *EXTERN*" <martin(at)bugs(dot)unl(dot)edu(dot)ar>, <pgsql-general(at)postgresql(dot)org>
Subject: Re: UTF-8 to ASCII
Date: 2007-05-11 13:16:55
Message-ID: AFCCBB403D7E7A4581E48F20AF3E5DB202A98F8E@EXADV1.host.magwien.gv.at
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

> I have a doubt about the function to_ascii() and what the
> documentation says.
>
> Basically, I passed my DB from latin1 to UTF-8, and I started

What do you mean by 'passed the DB from Latin1 to UTF8'?

> getting an error when using the to_ascii() function on a field
> of one of my DB [1]:
>
> ERROR: la conversión de codificación de UTF8 a ASCII no está soportada
>
> OK, it's in spanish, but basically it says that the conversion
> UTF8 to ASCII is not supported, but in the documentation [2] I see
> this in the "Table 9-7. Built-in Conversions":
>
> utf8_to_ascii UTF8 SQL_ASCII
>
> Is the documentation wrong or something?
>
> I'm on postgresql-8.1.8, and as you can see, I'm checking the
> corresponding documentation.
>
> [1]: This I already solved using convert() to pass from UTF
> to Latin1, and after that I do a to_ascii().
> [2]:
> http://www.postgresql.org/docs/8.1/interactive/functions-string.html#FTN.AEN7625

Well, the documentation for to_ascii states clearly:
"The to_ascii function supports conversion from LATIN1, LATIN2,
LATIN9, and WIN1250 encodings only."

The table of conversions you quote belongs to the function convert().

So that should answer your question.

I am not sure what you are trying to achieve.
If you tell us, I might be able to tell you HOW to achieve it.

Yours,
Laurenz Albe

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Ron Johnson 2007-05-11 13:20:43 Re: Fault Tolerant Postgresql (two machines, two postmasters, one disk array)
Previous Message Arnaud Lesauvage 2007-05-11 12:57:51 Re: UTF-8 to ASCII