Re: Date Formatting

Поиск
Список
Период
Сортировка
От Oliver Elphick
Тема Re: Date Formatting
Дата
Msg-id 1020467606.11663.53.camel@linda
обсуждение исходный текст
Ответ на Date Formatting  (Tom Ansley <tansley@law.du.edu>)
Список pgsql-novice
On Fri, 2002-05-03 at 20:31, Tom Ansley wrote:
> I am writing timestamps to file and the formatting is currently 2002-06-06
> 00:00:00.0.  Is there a function to only write the date and also to format it
> something like MM/dd/yyyy   ?

to_char(timestamp,format_text)

For your particular example, format_text = 'MM/DD/YYYY'

Users' Manual section 4.7

--
Oliver Elphick                                Oliver.Elphick@lfix.co.uk
Isle of Wight                              http://www.lfix.co.uk/oliver
GPG: 1024D/3E1D0C1C: CA12 09E0 E8D5 8870 5839  932A 614D 4C34 3E1D 0C1C

     "Live in harmony with one another. Do not be proud, but
      be willing to associate with people of low position.
      Do not be conceited."            Romans 12:16

Вложения

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

Предыдущее
От: Tom Ansley
Дата:
Сообщение: Date Formatting
Следующее
От: Vijay Deval
Дата:
Сообщение: Re: Tricky query