| От | Tom Lane |
|---|---|
| Тема | Re: lower and upper not UTF-8 safe |
| Дата | |
| Msg-id | 11538.1060030982@sss.pgh.pa.us обсуждение исходный текст |
| Ответ на | lower and upper not UTF-8 safe (Julian Satchell <j.satchell@eris.qinetiq.com>) |
| Ответы |
Re: lower and upper not UTF-8 safe
|
| Список | pgsql-hackers |
Julian Satchell <j.satchell@eris.qinetiq.com> writes:
> The implementations of lower and upper in
> src/backend/utils/adt/oracle_compat.c use the single byte macros from
> ctype.h to alter individual bytes in the text string.
> If the text is UTF-8 encoded this is totally wrong, and will result in
> an invalid string that is no longer UTF-8.
Only if you use a locale that is assuming a character set that is not
UTF8 but does have characters with the high bit set. I'm not sure that
we can do anything to defend against locale/charset mismatch.
regards, tom lane
В списке pgsql-hackers по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера