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

Re: Time conversion across various parts of world

From: John R Pierce <pierce(at)hogranch(dot)com>
To: deepthi(at)granwill(dot)com
Cc: pgsql-jdbc(at)postgresql(dot)org
Subject: Re: Time conversion across various parts of world
Date: 2004-11-26 07:12:15
Message-ID: 41A6D74F.2020002@hogranch.com (view raw or flat)
Thread:
Lists: pgsql-jdbc
deepthi(at)granwill(dot)com wrote:
> Hello,
> 
> For example, our website is running on a server located in Japan and we have
> another website #2 running in US. our database is located on the server in
> Japan. when some one accesses our website #2 which is located in US, the time
> at which the user accessed our website #2 has to be registered in a database
> which is situated in Japan. but at present i am getting the system time of the
> server which is in japan.  How can i convert this time or get the corresponding
> time at US using pgsql time zone feature or if anything else.
> 
> Please note: Our other website#2 can be located in other parts of the world
> also, it need not be US only. I have the country name where our  website#2 is
> located and by using this name i need to get the time in that country.

store GMT in the database always, convert back to local time when you display it.



In response to

Responses

pgsql-jdbc by date

Next:From: Tom LaneDate: 2004-11-26 18:17:26
Subject: Re: Time conversion across various parts of world
Previous:From: deepthiDate: 2004-11-26 07:05:47
Subject: Time conversion across various parts of world

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