Sort by foreign date column

Поиск
Список
Период
Сортировка
От Andrey Y. Mosienko
Тема Sort by foreign date column
Дата
Msg-id 3B81E839.CC622170@ttn.ru
обсуждение исходный текст
Ответы Re: Sort by foreign date column  (Stephan Szabo <sszabo@megazone23.bigpanda.com>)
Список pgsql-general
I have table with date type column:

chdate date;

SELECT chdate from mytable;

   chdate
 1999-01-02

But in Russia we have the next date format: DD-MM-YYYY.

When I do coversion to char in SELECT:
TO_CHAR(chdate,'DD-MM-YYYY') everything is ok, but sort by this column
executes as sort for char type.

How can I display my native date format and do right sorting by this column?

--
with respection Andrey Feofilactovich.
e-mail: feo@ttn.ru, feo@feo.org.ru
ICQ: 28073807

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

Предыдущее
От: will trillich
Дата:
Сообщение: not grokking outer joins...
Следующее
От: Stephan Szabo
Дата:
Сообщение: Re: Re: is this possible? it should be!