Re: Timestamp without Timezone and differing client / server tzs

From: Ken Johanson <pg-user(at)kensystem(dot)com>
To: Oliver Jowett <oliver(at)opencloud(dot)com>
Cc: pgsql-jdbc(at)postgresql(dot)org
Subject: Re: Timestamp without Timezone and differing client / server tzs
Date: 2008-07-09 04:08:56
Message-ID: 487439D8.2050508@kensystem.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

Oliver Jowett wrote:
> Ken Johanson wrote:
>
>> Question: with ts without tz storage, should not a timestamp be
>> normalized to the servers implicit TZ (UTC in this case), since that
>> is set in the config's client-tz?
>
> If you don't specify a Calendar to setTimestamp, it's assumed you mean
> the client JVM's default timezone (the same timezone that
> Timestamp.toString() assumes).

.......

> If you want to interpret a Timestamp as being in a particular timezone,
> use the getTimestamp()/setTimestamp() variants that take an explicit
> Calendar.

So, short of passing a calendar to setTimezone, there is no other way to
indicate to the driver that zone-less date/time type values should be
translated to the server's different timezone, is this correct?

k

In response to

Responses

Browse pgsql-jdbc by date

  From Date Subject
Next Message Oliver Jowett 2008-07-09 04:15:15 Re: Timestamp without Timezone and differing client / server tzs
Previous Message Scott Langley 2008-07-08 22:54:44 Patch to allow setting schema/search_path in the connectionURL