Search Postgresql Archives

Re: timezone() with timeofday() converts the wrong direction?

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

 



>
> Perhaps this is what you want:
>
>   SELECT timezone('UTC', timeofday()::timestamptz);

That did it. Strangely, I thought I had tried that already, but I must not
have. My next question would be if I did:

	SELECT timezone('UTC', timeofday()::timestamptz):timestamptz;

Why do I get the timezone value as being -07(my local offset), instead
of -00?

Thanks,
Steve



---------------------------(end of broadcast)---------------------------
TIP 4: Don't 'kill -9' the postmaster

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux