ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Andrey Rogov" <andrey.ro...@gmail.com>
Subject Re: Retrieving Oracle column with data type TIMESTAMP WITH LOCAL TIME ZONE
Date Tue, 18 Mar 2008 01:43:16 GMT
Jess,
   try to execute sql operator ALTER SESSION before accessing TIMESTAMP WITH
LOCAL TIME ZONE data

   <update id="setTimeZone" parameterClass="java.lang.String">
        ALTER SESSION SET time_zone = #timezonevalue#
   </update>





2008/3/17, Jesse Reimann <jreimann@ctigroup.com>:
>
>  I'm trying to retrieve an Oracle column that is defined as TIMESTAMP WITH
> LOCAL TIME ZONE. Currently I'm receiving an error stating
>
>
>
> --- Cause: *java.sql.SQLException*: Session Time Zone not set!
>
>
>
> Looking into it I need to specify the Session Time Zone as part of the
> Oracle JDBC Connection properties.
>
>
>
> I found this in an Oracle document when searching for a solution:
>
>
>
> Before accessing TIMESTAMP WITH LOCAL TIME ZONE data, call the
> OracleConnection.setSessionTimeZone(String regionName) method to set the
> session time zone. When this method is called, the JDBC driver sets the
> session time zone of the connection and saves the session time zone so that
> any TIMESTAMP WITH LOCAL TIME ZONE data accessed through JDBC can be
> adjusted using the session time zone.
>
>
>
>
>
> So my question is how would I go about calling the setSessionTimeZone
> method of the OracleConnection when using iBATIS (and Spring).
>
>
>
> Thanks,
>
>
>
> Jesse Reimann
>

Mime
View raw message