Re: Another date / time question

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Another date / time question
Дата
Msg-id 25059.1080321719@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Another date / time question  ("Vanole, Mike" <mike.vanole@attws.com>)
Ответы Re: Another date / time question  (Bruno Wolff III <bruno@wolff.to>)
Список pgsql-general
"Vanole, Mike" <mike.vanole@attws.com> writes:
> I'm trying to query two timestamp(0) columns to determine elapsed time. I u=
> se the age() function which works fine, but I want to return the informatio=
> n in MINUTES.=20

Just subtract (giving an interval), use extract(epoch) to get the
interval in seconds, then divide by 60 and round (or truncate if you
prefer).

            regards, tom lane

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: pg_dump is missing data
Следующее
От: "Guy Rouillier"
Дата:
Сообщение: Physical Database Configuration