Re: Importing data w/ Unix timestamp

Поиск
Список
Период
Сортировка
От Ed Loehr
Тема Re: Importing data w/ Unix timestamp
Дата
Msg-id 395B8CCC.A2756957@austin.rr.com
обсуждение исходный текст
Ответ на Importing data w/ Unix timestamp  (brianb-pggeneral@edsamail.com)
Список pgsql-general
Thomas Lockhart wrote:
>
> > insert into RealTable select uname, timestamp(abstime(timeinAsInt4)),
> >                              duration, etc from TempTable;
>
> Another side comment: afaik an explicit conversion to abstime is not
> required to go from Unix time to timestamp. So
>
>   insert into RealTable select uname, timestamp(timeinAsInt4),
>                                duration, etc from TempTable;
>
> should be equivalent.

Neat.  BTW, the documentation on date/time functions at

    http://www.postgresql.org/docs/postgres/x2876.htm

does not hint at this capability.

Regards,
Ed Loehr

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

Предыдущее
От: Thomas Lockhart
Дата:
Сообщение: Re: Importing data w/ Unix timestamp
Следующее
От: "Mitch Vincent"
Дата:
Сообщение: Trigger question.. (Heaptuple struct)