Received: from localhost (maia-5.hub.org [200.46.204.182]) by postgresql.org (Postfix) with ESMTP id 9A2929FB58C for ; Fri, 23 Feb 2007 08:39:34 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.182]) (amavisd-new, port 10024) with ESMTP id 95133-06 for ; Fri, 23 Feb 2007 08:39:26 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey-1.7.4 Received: from matrix.gatewaynet.com (host2.dynacom.ondsl.gr [62.103.35.210]) by postgresql.org (Postfix) with ESMTP id BDDA49FB583 for ; Fri, 23 Feb 2007 08:39:30 -0400 (AST) Received: from host3.dynacom.ondsl.gr ([62.103.35.211] helo=ip216.internal.net) by matrix.gatewaynet.com with esmtp (Exim 4.62) (envelope-from ) id 1HKZhu-0001f3-RI for pgsql-admin@postgresql.org; Fri, 23 Feb 2007 14:39:26 +0200 From: Achilleas Mantzios Organization: Dynacom Tankers Mgmt To: pgsql-admin@postgresql.org Subject: Re: can i use to_ascii function ? Date: Fri, 23 Feb 2007 14:39:24 +0200 User-Agent: KMail/1.9.3 References: <46f93e0d0702230412i7a576ef9jd85c2823fa2c65e5@mail.gmail.com> In-Reply-To: <46f93e0d0702230412i7a576ef9jd85c2823fa2c65e5@mail.gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Message-Id: <200702231439.25906.achill@matrix.gatewaynet.com> X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0.186 tagged_above=0 required=5 tests=AWL, BAYES_50, FORGED_RCVD_HELO X-Spam-Level: X-Archive-Number: 200702/306 X-Sequence-Number: 24771 =CE=A3=CF=84=CE=B9=CF=82 =CE=A0=CE=B1=CF=81=CE=B1=CF=83=CE=BA=CE=B5=CF=85= =CE=AE 23 =CE=A6=CE=B5=CE=B2=CF=81=CE=BF=CF=85=CE=AC=CF=81=CE=B9=CE=BF=CF= =82 2007 14:12, =CE=BF/=CE=B7 j n =CE=AD=CE=B3=CF=81=CE=B1=CF=88=CE=B5: > Hi > > i need to get rid of acute, and other special symbols from letters. Is any > way how to do it easy in postgres ? > > i need conversion like this from slovak language ... : > > =C3=A9, =C4=9B -> e > =C3=A1, =C3=A4 -> a > =C5=A1 -> s > > i tried : > > SELECT to_ascii('=C5=A1=C4=8D=C4=8F=C5=A5') > > i get an error : ERROR: encoding conversion from UTF8 to ASCII not > supported > > that i found something like this > > SELECT convert('=C5=A1=C4=8D=C4=8F=C5=A5', 'UTF8', 'LATIN1') > > i get an error : ERROR: character 0xc5a1 of encoding "UTF8" has no > equivalent in "LATIN1" > > Is any way how to do it ? > If there is not build in support for this conversion can i create my own ? Trying to resort to iso-8859-2 (the western slavic script) is not doing you= =20 any good, since you simply recode those chars in UTF-8 to their latin2 counterparts. How about=20 translate('your slovak text','=C3=A9=C4=9B=C3=A1=C3=A4=C5=A1','eeaas'); > > pls help =2D-=20 Achilleas Mantzios