Java: Alter Oracle Session Information using iBATIS
By admin on Feb 17, 2009 in Java, Oracle, Programming
There are times that you may want to alter Oracle session information. If you are using iBATIS, this can be done the following way
Create the update statement. E.g.
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE sqlMap PUBLIC "-//ibatis.apache.org//DTD SQL Map 2.0//EN" "http://ibatis.apache.org/dtd/sql-map-2.dtd" >
<sqlMap namespace="TEST">
<update id="update_sort_area_size" parameterClass="int">
alter session set sort_area_size=#value#
</update>
<update id="update_sort_area_retained_size" parameterClass="int">
alter session set sort_area_retained_size=#value#
</update>
</sqlMap>
Then just use the SqlMapClient.update method to call the respective statement. E.g.
Integer val = 65535;
sqlMapClient.update("update_sort_area_size",val);
Sorry, comments for this entry are closed at this time.