Skip site navigation (1) Skip section navigation (2)

Re: Timestamp with time zone

From: Xavier Robin <xavier(dot)robin(at)bluewin(dot)ch>
To: pgsql-novice(at)postgresql(dot)org
Subject: Re: Timestamp with time zone
Date: 2010-07-01 07:25:12
Message-ID: 4C2C42D8.5000302@bluewin.ch (view raw or flat)
Thread:
Lists: pgsql-novice
Le 30.06.2010 18:59, Tim Landscheidt a Ă©crit :
> Xavier Robin <xavier(dot)robin(at)bluewin(dot)ch> wrote:
>> Just one more question to make sure I got it all right:
> 
>> EXTRACT(timezone FROM <a timestamptz here>)
> 
>> will *always* return 0? Because the doc suggests that positive or
>> negative values can be returned…
> 
> No, it will return the offset of your current time zone:

I got it, thanks a lot! :)
So WITH TIME ZONE was not at all what I expected (thought it would store
the time zone of the timestamp entered). I'll see if switching to
TIMESTAMP WITHOUT TIME ZONE is what I need now.

Thanks all for your answers and insights.

Xavier

In response to

pgsql-novice by date

Next:From: Thom BrownDate: 2010-07-01 08:31:10
Subject: Re: null vs empty string
Previous:From: MickDate: 2010-07-01 03:59:53
Subject: Re: null vs empty string

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group