Re: Division of intervals.

Поиск
Список
Период
Сортировка
От Bruno Wolff III
Тема Re: Division of intervals.
Дата
Msg-id 20030319111314.GA702@wolff.to
обсуждение исходный текст
Ответ на Re: Division of intervals.  (Joshua Moore-Oliva <josh@chatgris.com>)
Ответы Re: Division of intervals.  (Joshua Moore-Oliva <josh@chatgris.com>)
Список pgsql-general
On Wed, Mar 19, 2003 at 01:03:50 -0500,
  Joshua Moore-Oliva <josh@chatgris.com> wrote:
> I guess that it does for this problem..  But I have other applications that
> require the number of days...  and that gets a lot more complex to work out.

If you subtract the timestamps the interval will have 0 for the month/year
part and you can extract the epoch from it to get the time in seconds.
This can be divided by 24*60*60 to get days.

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

Предыдущее
От: "Nigel J. Andrews"
Дата:
Сообщение: Re: ssl
Следующее
От: Joshua Moore-Oliva
Дата:
Сообщение: Re: Division of intervals.