ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Rao, Satish" <satish....@fmr.com>
Subject RE: Stored procedures returning resultset
Date Tue, 09 Aug 2005 14:39:16 GMT
So in that case if I want to return a list of employees based on some
search criteria, will the setting below work?

<resultMap id="proc-result" class="com.Result">
	<result property="empId" column="EMP_ID"/>	
	<result property="firstName" column="FNAME"/>
	<result property="lastName" column="LNAME"/>
<parameterMap id="proc_param" class="com.Filter">
	<parameter property="filter1" mode="IN" jdbcType="NUMBER"
	<parameter property="filter2" mode="IN" jdbcType="VARCHAR"
<procedure id="listRunsByCampaignAndRunFilter"
parameterMap="campaign-run-param" resultMap="proc-result">
	{call PROCEDURE_NAME(?,?)}

In the stored procedure what will be the return type, since there is no
OUT parameter?

Do you have an example?

-----Original Message-----
From: Koka [mailto:226057@gmail.com] 
Sent: Tuesday, August 09, 2005 10:29 AM
To: user-java@ibatis.apache.org
Subject: Re: Stored procedures returning resultset

Well, it may be reasonable to avoid ref_cursors at all as it is oracle
specific. So in your procedure you can just insert data you want to
return to some temp table and then just run select.  I have been using
that appoach in the old days when I had to use ADO (thank God that
days have gone :) ) and there seemed no ref_cursor support at all.


View raw message