DATE field subtraction

From: Ralph Graulich <maillist(at)shauny(dot)de>
To: pgsql-general(at)postgresql(dot)org
Subject: DATE field subtraction
Date: 2002-08-19 10:33:34
Message-ID: Pine.LNX.4.21.0208191232060.479-100000@shauny.shauny.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi,

I assume I am just to blind to find it in the documentation: I have a DATE
field and want to subtract 4 weeks.

SELECT [...]
FROM table
WHERE datefield >= '2002-08-19' - interval '4 weeks'

Kind regards
... Ralph ...

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Peter Gibbs 2002-08-19 10:49:50 Re: DATE field subtraction
Previous Message Joel Rees 2002-08-19 10:17:00 Re: postgresql euc/sjis utf8 mappings