Re: order by accents?
| От | Manuel Sugawara |
|---|---|
| Тема | Re: order by accents? |
| Дата | |
| Msg-id | m3ya393hts.fsf@dep1.fciencias.unam.mx обсуждение исходный текст |
| Ответ на | Re: order by accents? (ERIC Lawson - x52010 <eric@bioeng.washington.edu>) |
| Список | pgsql-novice |
ERIC Lawson - x52010 <eric@bioeng.washington.edu> writes: > > > hi, > > if I do a query like this one : > > > > SELECT name from medias ORDER BY name > > > > name > > ---- > > AAAA > > CCCC > > EEEE > > VVVV > > ZZZZ > > �CCC > > ---- > > 6 rows > > > > > > Why the record : �CCC is at the end? > > HOW can I fix this? By default postgres uses the standard "C" locale to sort it's results. Is your postgres installation compiled with locale support?, If it is, you can use environment variables such as LC_CTYPE to tell postgres how to sort characters. For example with LC_CTYPE=es (Spanish) your select will return: name ---- AAAA CCCC �CCC EEEE VVVV ZZZZ ---- 6 rows Which may be what you was expecting. HTH. Regards, Manuel.
В списке pgsql-novice по дате отправления: