Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Java > Converting from one timezone to another

Reply
Thread Tools

Converting from one timezone to another

 
 
kramesh kramesh is offline
Junior Member
Join Date: Apr 2009
Posts: 2
 
      04-20-2009
HI All,

Version: Java 1.5
Database: Oracle 10g

I have a date column in a table. Using the JDBC call I retrieve the date using:

Timestamp datetime = ResultSet.getTimestamp();

Now I want to convert this into a different time zone. For Example, if the database has "10-APR-2009 22:00:00" and if the JVM's timezone is America/Los_Angeles, it will be read as "10-APR-2009 22:00:00 PST". Now I want to convert this into IST time and date. So, it should be converted "11-APR-2009 10:30:00 IST".

Please let me know how to do this.

Regards
 
Reply With Quote
 
 
 
 
kramesh kramesh is offline
Junior Member
Join Date: Apr 2009
Posts: 2
 
      04-21-2009
Please help.
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
TimeZone change - how to use TimeZone class axrock Java 8 03-25-2009 11:54 PM
TimeZone calculation on Windows Vista with DateTime::TimeZone Ami Perl Misc 5 09-24-2007 07:27 AM
Convert windows TimeZone to Java TimeZone asaf Java 3 09-11-2006 05:40 PM
Converting the time from one timezone to another Nathan Sokalski ASP .Net 5 03-02-2006 04:13 PM
Converting the time from one timezone to another Nathan Sokalski ASP .Net Building Controls 6 03-02-2006 04:13 PM



Advertisments