I've got a case similar to the code in the hibernate3 documentation:
Code:
<class name="com.spod.LookupValue" table="dummy">
<id name="id" column="dummy1"/>
<property name="text" column="dummy2"/>
<property name="sourceType" column="dummy3"/>
<loader query-ref="load-lookup"/>
<sql-insert callable="true">{? = call insertFunc3(?, ?, ?)}</sql-insert>
</class>
Now, I get an error that not all variables are bound. Wait! Read further.
My SP is:
Code:
CREATE OR REPLACE function insertFunc3(textParam in varchar2(20), sourceParam in varchar2(20), newId out integer)
return integer
I understand that the return value counts as a variable, and so I only supply 3 variables, where 4 are required.
But how
do I call this function? Ideally I only want to supply the two properties, and have the generated key returned to me as the return value from the SP.
Thanks.