Re: Date addition/subtraction - Mailing list pgsql-general

From Scott Marlowe
Subject Re: Date addition/subtraction
Date
Msg-id 1115142732.13303.1500.camel@state.g2switchworks.com
Whole thread Raw
In response to Date addition/subtraction  ("Craig Bryden" <postgresql@bryden.co.za>)
List pgsql-general
On Tue, 2005-05-03 at 12:32, Craig Bryden wrote:
> Hi
>
> How in postgres can I do date/time subtraction or addition.
> e.g. If I want to get today's date - 30 days? or current_timestamp - 1 hour?


select now()-interval'1 hour'

and so on.

pgsql-general by date:

Previous
From: Scott Marlowe
Date:
Subject: Re: Sorting by constant values
Next
From: Ragnar Hafstað
Date:
Subject: Re: Date addition/subtraction