Re: subquery involving 'now'

From: Stephan Szabo <sszabo(at)megazone23(dot)bigpanda(dot)com>
To: <jmycr(at)cs(dot)com>
Cc: <pgsql-sql(at)postgresql(dot)org>
Subject: Re: subquery involving 'now'
Date: 2002-03-13 16:04:47
Message-ID: 20020313080353.S81426-100000@megazone23.bigpanda.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql


On Thu, 7 Mar 2002 jmycr(at)cs(dot)com wrote:

> SELECT a.backup_id, a.archive_id, a.file_name, a.file_size, b.something
> FROM archive a, burp b
> WHERE a.aname = b.aname and a.backup_date < 'now'::datetime - '(select maxday_savefile from service) days'::timespan;
>
> this does not work, any suggestions

Maybe
- ((select maxday_savefile from service) || ' days')::timespan

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Jan Wieck 2002-03-13 16:29:26 Re: Large data sets and FOR LOOP's
Previous Message Stephan Szabo 2002-03-13 16:02:28 Re: ALTER CONSTRAINT FOREIGN KEY