Search Postgresql Archives

Re: Input timestamp from epoch?

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

 



am  19.08.2005, um  0:27:40 -0700 mailte Bill Moseley folgendes:
> I'm entering data into a Postgresql database where the input dates are
> currently in unix epoch values.  Is there a way for Postgresql to
> parse that epoch into a "timestamp(0) with time zone"?

SELECT TIMESTAMP WITH TIME ZONE 'epoch' + 1124438230 * INTERVAL '1 second';
                                          ^^^^^^^^^^
                                          your epoch


Regards, Andreas
-- 
Andreas Kretschmer    (Kontakt: siehe Header)
Heynitz:  035242/47212,      D1: 0160/7141639
GnuPG-ID 0x3FFF606C http://wwwkeys.de.pgp.net
 ===    Schollglas Unternehmensgruppe    === 

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

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux