Can you tell us what 'post-processing' you need to do on the result set? -Richard
-----Original Message----- From: Satish Kumar [mailto:[EMAIL PROTECTED] Sent: Friday, January 05, 2007 4:34 PM To: [email protected] Subject: Re: Handle to ResultSet I did see that entry, but the example provided there maps the resultSet to a resultMap. I need the handle to the raw ResultSet. Thanks for your reply. Rgds Satish ----- Original Message ---- From: Jan Vissers <[EMAIL PROTECTED]> To: [email protected] Sent: Friday, January 5, 2007 3:41:03 PM Subject: Re: Handle to ResultSet Note sure whether you followed this Wiki entry: http://opensource.atlassian.com/confluence/oss/pages/viewpage.action?pageId= 5653 <http://opensource.atlassian.com/confluence/oss/pages/viewpage.action?pageId =5653> > Hi, > > I am a new user of iBATIS Ver 2.3.0. I have a requirement to get the > handle to the ResultSet from iBATIS for post-processing. > > The ResultSet is from a Oracle Ref Cursor returned by a stored procedure. > I followed the examples mentioned on the iBATIS Wiki and mailing lists, > but have not had success. > > I am using JDK 1.5, the latest version of Oracle 10g JDBC drivers. > > Below is the SQLMap > > <?xml version="1.0" encoding="UTF-8" ?> > http://ibatis.apache.org/dtd/sql-map-2.dtd" <http://ibatis.apache.org/dtd/sql-map-2.dtd%22> ;> > > <sqlMap> > <parameterMap id="listErrorParameters" class="java.util.Map"> > <parameter property="serverId" jdbcType="NUMERIC" mode="IN"/> > <parameter property="resultSet" javaType="java.sql.ResultSet" > jdbcType="ORACLECURSOR" mode="OUT"/> > </parameterMap> > > <procedure id="listError" parameterMap="listErrorParameters" > > {call listError(?,?)} > </procedure> > </sqlMap> > > Sample Program: > > public static main(String[] args) { > try{ > String resource; > Reader reader; > > SqlMapClient sqlMap; > resource = "sqlMap-config.xml"; > reader = Resources.getResourceAsReader (resource); > sqlMap = SqlMapClientBuilder.buildSqlMapClient(reader); > > Map paramsMap = new HashMap(); > paramsMap.put("id", "1000"); > > sqlMap.queryForObject("listError", paramsMap); > > System.out.println("resultSet: " + paramsMap.get("resultSet")); > > }catch(Exception aoExec) > { > aoExec.printStackTrace(); > } > } > > In the above program paramsMap.get("resultSet") always returns null, and I > am not sure why? > > Any help would be greatly appreciated. > > Thanks > Satish > > > > __________________________________________________ > Do You Yahoo!? > Tired of spam? Yahoo! Mail has the best spam protection around > http://mail.yahoo.com <http://mail.yahoo.com> __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com
