From: | "Mitch Vincent" <mvincent(at)cablespeed(dot)com> |
---|---|
To: | "Chris Ruprecht" <chrup999(at)yahoo(dot)com>, "p-php" <pgsql-php(at)postgresql(dot)org> |
Subject: | Re: Date Manipulations |
Date: | 2001-07-11 16:39:32 |
Message-ID: | 000d01c10a28$13ac67c0$1a0d040a@Mitch |
Views: | Whole Thread | Raw Message | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-php |
Well, it depends on what you're trying to do :-)
You can add days an arbitrary date in a number of ways , I often let PG
handle it though (as you are)..
I generally do something like
SELECT ('05-05-2001'::date + '5 days'::interval)
Or something like that if I need X days ahead or behind date Y...
----- Original Message -----
From: "Chris Ruprecht" <chrup999(at)yahoo(dot)com>
To: "p-php" <pgsql-php(at)postgresql(dot)org>
Sent: Wednesday, July 11, 2001 10:06 AM
Subject: [PHP] Date Manipulations
> Hi all,
>
> Currently, when working with dates, I use constructs like
>
> ('$NewDate'::date + 5)::date
>
> this seems a little clumsy to me and I was wondering if there was an
easier
> way of doing this.
>
> Best regards,
> Chris
>
>
>
> _________________________________________________________
> Do You Yahoo!?
> Get your free @yahoo.com address at http://mail.yahoo.com
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 2: you can get off all lists at once with the unregister command
> (send "unregister YourEmailAddressHere" to majordomo(at)postgresql(dot)org)
>
From | Date | Subject | |
---|---|---|---|
Next Message | Chris Ruprecht | 2001-07-11 17:56:28 | Re: Date Manipulations |
Previous Message | Chris Ruprecht | 2001-07-11 14:06:56 | Date Manipulations |