Re: [PHP] Converting RFC 2822 "timestamp" to timestampz

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

On 12/10/05, Steve Crawford <scrawford@xxxxxxxxxxxxxxxxxxxx> wrote:
> On Wednesday 12 October 2005 12:14, Milen A. Radev wrote:
> > I have a RFC2822 timestamp (example: Thu, 21 Dec 2000 16:01:07
> > +0200). I need to convert it to "timestampz" but I stumbled on the
> > timezone conversion....
> The following works for me:
> # select 'Thu, 21 Dec 2000 16:01:07 +0200'::timestamptz;
>       timestamptz
> ------------------------
>  2000-12-21 06:01:07-08

You are so right! I was confused by another bug in my query to believe
that the RFC2822 format is unacceptable.

Milen A. Radev

---------------------------(end of broadcast)---------------------------
TIP 1: if posting/reading through Usenet, please send an appropriate
       subscribe-nomail command to majordomo@xxxxxxxxxxxxxx so that your
       message can get through to the mailing list cleanly

[Postgresql General]     [Postgresql Admin]     [PHP Users]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Databases]     [Yosemite Backpacking]     [Postgresql Jobs]

Add to Google Powered by Linux