0 Replies Latest reply on Apr 9, 2003 4:54 PM by courtney

    how to set timezone for date retrieved by EJB from database

    courtney

      I have a database containing "date" data which is a time and date relative to the GMT timezone (the SQL date type does support explicit specification of the timezone, so the user of the database must "know" the timezone associated with that data). When I retrieve the data through an EJB, the Java Date data that is returned is set to my local timezone, but the time value is exactly as it is stored in the database, which is GMT. So, the time represented in the Java date is in error by hours corresponding to the number of timezones between my local timezone and GMT.

      How do I specify the timezone to the JBoss SQL to Java data converter so it correctly interprets the date/time data in the database?