Re: Converting POSTGRESQL timestamp to UNIX timestamp

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



select date_part('epoch', timestamp(topics.date_added)) from table;

On Thu, 22 Mar 2001, Richie wrote:

> Hi
> 
> I have a field of type timestamp in my database but when I retrieve it I
> want to convert it to its unix timetamp value because I need to compare 2
> tables by their timestamp value.
> 
> Any ideas how to convert PostgreSQL timestamp to Unix timestamp???
> 
> Thanks
> 
> Richie
> 
> =========================================================
> Richie Duggan 
> Computer Science IV
> University College Cork
> Eamil : dugganr@xxxxxxxxxxxxxxxxx   richie_dug@xxxxxxxxx
> Homepage : http://student.cs.ucc.ie/01/dugganr/index.html
> 
> 
> ---------------------------(end of broadcast)---------------------------
> TIP 3: if posting/reading through Usenet, please send an appropriate
> subscribe-nomail command to majordomo@xxxxxxxxxxxxxx so that your
> message can get through to the mailing list cleanly
> 


---------------------------(end of broadcast)---------------------------
TIP 4: Don't 'kill -9' the postmaster





[Index of Archives]     [Postgresql General]     [Postgresql Admin]     [PHP Users]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Databases]     [Yosemite Backpacking]     [Postgresql Jobs]

  Powered by Linux