View Single Post

   
  #3 (permalink)  
Old 02-27-2008, 01:11 PM
Toralf =?utf-8?q?F=C3=B6rster?=
 
Posts: n/a
Default Re: Convert timestamp to yyyy-mm-dd format

yogi wrote:

> Hi,
> I am working on a database that has a variable with timestamp
> values. I wanted to convert the variable from timestamp to yyyy-mm-dd
> format.

select
varchar_format (your_column_name, 'YYYY-MM-DD HH24:MI:SS')
from
your_table

and for an export statement use sth like

EXPORT TO my_file OF DEL MODIFIED BY COLDEL;
TIMESTAMPFORMAT=\"dd.mm.yyyy hh:mm\"
select * from foo


--
Toralf Förster
pgp key 0x7DB69DA3


Reply With Quote