ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Roger Voss" <rog...@qwest.net>
Subject Re: "resultMap" must be declared for element type "parameter".
Date Mon, 05 Jan 2009 02:07:58 GMT
Turn your Oracle procedure call into a function where the cursor is returned
as the function result and then wrap the call like so:

SELECT *
FROM TABLE(Tree.GETTREEINFO(?))

You will then be able to get iBATIS to map this using a resultMap definition
- just as though were selecting from an ordinary table.

On Mon, Dec 29, 2008 at 7:02 AM, DH12 <dharmesh.borad@gmail.com> wrote:

>
> Hello,
>
> I am trying to get result from refrence cursor.
> Here is my entry...
>
>
> <resultMap id="treeInfoMap" class="xyz.TreeInfoVO" >
>     <result property="nodeID" column="NODE_ID" />
>    <result property="nodeType" column="NODE_TYPE" />
>  </resultMap>
>
>  <parameterMap id="paramMap" class="java.util.Map" >
>    <parameter property="nodeID" jdbcType="NUMERIC"
> javaType="java.lang.String" mode="IN"/>
>
>    <parameter property="treeInfo" javaType="java.sql.ResultSet"
> jdbcType="ORACLECURSOR" mode="OUT" resultMap="treeInfoMap"/>
>  </parameterMap>
>
>  <select id="pro1" parameterMap="paramMap" >
>     { call Tree.GETTREEINFO(?,?) }
>  </select>
>
>
> And my DTD is...
>
> <!DOCTYPE sqlMap
>    PUBLIC "-//iBATIS.com//DTD SQL Map 2.0//EN"
>    "http://www.ibatis.com/dtd/sql-map-2.dtd">
>
>
> If any solution on that will appreciate.
> I gone threw so many places in google but it seems no one has solutions.
>
> Thanks
> --
> View this message in context:
> http://www.nabble.com/%22resultMap%22-must-be-declared-for-element-type-%22parameter%22.-tp21204286p21204286.html
> Sent from the iBATIS - User - Java mailing list archive at Nabble.com.
>
>

Mime
View raw message