Re: BUG #13440: unaccent does not remove all diacritics

Поиск
Список
Период
Сортировка
От Michael Gradek
Тема Re: BUG #13440: unaccent does not remove all diacritics
Дата
Msg-id CAEP8ZNWBH7Lc8KeaAxbPFJAC-RUUCKfBv5xcfOjqKvf4309Esw@mail.gmail.com
обсуждение исходный текст
Ответ на Re: BUG #13440: unaccent does not remove all diacritics  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: BUG #13440: unaccent does not remove all diacritics
Список pgsql-bugs
Hi Tom,

Thanks for looking into this issue. Would this help?

> psql -l

                                                List of databases

          Name          |     Owner     | Encoding |   Collate   |
Ctype    |        Access privileges

------------------------+---------------+----------+-------------+---------=
----+---------------------------------

 grand-central          | michaelgradek | UTF8     | en_US.UTF-8 |
en_US.UTF-8 |


Here's a case showing the transformation failing, and another succeeding

> psql grand-central

psql (9.4.1, server 9.3.5)

Type "help" for help.


grand-central=3D# select '=C8=9B' as input, unaccent('=C8=9B') as observed,=
 't' as
expected;

 input | observed | expected

-------+----------+----------

 =C8=9B     | =C8=9B        | t

(1 row)


grand-central=3D# select '=C3=A9' as input, unaccent('=C3=A9') as observed,=
 'e' as
expected;

 input | observed | expected

-------+----------+----------

 =C3=A9     | e        | e

(1 row)


On Sun, Jun 14, 2015 at 1:59 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:

> mike@busbud.com writes:
> > Sorry, I couldn't install the most recent minor release, but I did try
> this
> > on several different versions. I used Heroku to try a 9.4.3 build, and
> got
> > the same results
>
> > select '=C8=9B' as input, unaccent('=C8=9B') as observed, 't' as expect=
ed;
> >  input | observed | expected
> > -------+----------+----------
> >  =C8=9B     | =C8=9B        | t
> > (1 row)
>
> Hm, I do see
>
> =C5=A3       t
>
> in unaccent.rules, so the transformation ought to happen.  I suspect
> an encoding issue, eg your terminal window is not transmitting characters
> in the encoding Postgres thinks you're using.  You did not provide any
> info about server encoding, client encoding, or client LC_xxx environment=
,
> so it's hard to debug from here.
>
>                         regards, tom lane
>



--=20
Cheers,
Mike
--=20
Mike Gradek
Co-founder and CTO, Busbud
Busbud.com <http://busbud.com/> | mike@busbud.com
*We're hiring!: Jobs at Busbud <http://www.busbud.com/en/about/jobs>*

В списке pgsql-bugs по дате отправления:

Предыдущее
От: Michael Paquier
Дата:
Сообщение: Re: BUG #13441: pg_settings.pending_restart cann't reflect changed setting in configure file.
Следующее
От: Thomas Munro
Дата:
Сообщение: Re: BUG #13440: unaccent does not remove all diacritics