From: | "Edward W(dot) Rouse" <erouse(at)comsquared(dot)com> |
---|---|
To: | <pgsql-sql(at)postgresql(dot)org> |
Subject: | Re: intervals |
Date: | 2011-11-03 17:59:08 |
Message-ID: | 00f601cc9a52$48e450e0$daacf2a0$@com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-sql |
In conjunction with Jonathan, this has gotten me to the point where it works, sort of. Now I just need to change it so that it does more than 1 at a time. Since it currently isn't in a loop, it affects one and quits. But I needed to get it to do that first, putting it in a loop should be the easy part.
Thanks.
> -----Original Message-----
> From: pgsql-sql-owner(at)postgresql(dot)org [mailto:pgsql-sql-
> owner(at)postgresql(dot)org] On Behalf Of bricklen
> Sent: Thursday, November 03, 2011 1:44 PM
> To: Edward W. Rouse
> Cc: pgsql-sql(at)postgresql(dot)org
> Subject: Re: [SQL] intervals
>
> On Thu, Nov 3, 2011 at 10:29 AM, Edward W. Rouse
> <erouse(at)comsquared(dot)com> wrote:
> > expire := '% days'::interval, limit;
>
> A couple ways spring to mind immediately. Using 10 as the example:
>
> expire := 10 * '1 day'::INTERVAL;
> expire := ('10' || ' days')::INTERVAL;
>
> --
> Sent via pgsql-sql mailing list (pgsql-sql(at)postgresql(dot)org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-sql
From | Date | Subject | |
---|---|---|---|
Next Message | Michael Glaesemann | 2011-11-03 18:20:40 | Re: intervals |
Previous Message | Edward W. Rouse | 2011-11-03 17:56:09 | Re: intervals |