Re: interval

From: Thomas Lockhart <lockhart(at)fourpalms(dot)org>
To: sec <sec(at)artofit(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: interval
Date: 2001-12-03 17:01:45
Message-ID: 3C0BAFF9.17274634@fourpalms.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

> How can i get time interval only in minutes or in seconds ?
> For example i have '1 month 15 days' and i need these time in
> minutes.

lockhart=# select extract(epoch from interval '1 month 15 days') / 60;
?column?
----------
64800
(1 row)

- Thomas

In response to

  • interval at 2001-12-03 14:55:54 from Yuri A. Kabaenkov

Responses

  • Re: interval at 2001-12-03 17:09:53 from Yuri A. Kabaenkov

Browse pgsql-general by date

  From Date Subject
Next Message Tom Lane 2001-12-03 17:05:14 Re: Should I use CAST?
Previous Message Doug McNaught 2001-12-03 16:51:46 Re: Determining current database programmatically