Re: Unicode Variation Selector and Combining character

Поиск
Список
Период
Сортировка
От Daniel Verite
Тема Re: Unicode Variation Selector and Combining character
Дата
Msg-id ebc75546-2409-4e9e-8275-fc74d1a76b31@manitou-mail.org
обсуждение исходный текст
Ответ на Re: Unicode Variation Selector and Combining character  (Thomas Munro <thomas.munro@gmail.com>)
Ответы RE: Unicode Variation Selector and Combining character  (荒井元成 <n2029@ndensan.co.jp>)
Список pgsql-hackers
    Thomas Munro wrote:

> Looking around a bit, it might be interesting to check if the
> icu_character_boundaries() function in Daniel Vérité's icu_ext treats
> IVSs as single grapheme clusters.

It does.

with strings(s) as (
 values (U&'\+0066FE' || U&'\+0E0103'),
    (U&'\+00304B' || U&'\+00309A')
)
select s,
  octet_length(s),
  char_length(s),
  (select count(*) from icu_character_boundaries(s,'en')) as graphemes
from strings;


  s  | octet_length | char_length | graphemes
-----+--------------+-------------+-----------
 曾󠄃 |        7 |          2 |      1
 か゚  |         6 |           2 |       1



Best regards,
--
Daniel Vérité
https://postgresql.verite.pro/
Twitter: @DanielVerite



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

Предыдущее
От: Aleksander Alekseev
Дата:
Сообщение: Re: [RFC] building postgres with meson
Следующее
От: Peter Eisentraut
Дата:
Сообщение: Re: Unicode Variation Selector and Combining character