Re: Getting timestamp without milliseconds

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Tadej Kanizar" <Tadej(dot)Kanizar(at)sagit-server(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Getting timestamp without milliseconds
Date: 2006-01-05 16:16:48
Message-ID: 18243.1136477808@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

"Tadej Kanizar" <Tadej(dot)Kanizar(at)sagit-server(dot)com> writes:
> I've got a timestamp field.. and it returns sth like "2006-01-04
> 21:33:17.156". How can I get the same result, just without the .156?

Cast to timestamp(0).

regards, tom lane

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Steve Crawford 2006-01-05 16:22:01 Re: 'Official' definition of ACID compliance?
Previous Message Scott Marlowe 2006-01-05 16:16:36 Re: Getting timestamp without milliseconds