hello sir,
I have a stored proc [b]TESTSELECTSP [/b] written in firebird DB:
CREATE PROCEDURE TESTSELECTSP
RETURNS
(
VBOOKNAME VARCHAR(50),
VAUTHOR VARCHAR(50),
VPUBLICATION VARCHAR(50),
VPRICE INTEGER
)
AS
BEGIN
For Select BookName,Publication,Author,Price from Books
into :vBookName,vAuthor,vPublication,vPrice Do
Begin
suspend;
End END ^
I have the below code written for mapping,
[code]<sql-query name="_TESTSELECTSP">
<return class="TestNIHIBwithFireBird.BookDetails,TestNIHIBwithFireBird">
<return-property name="BOOKNAME" column="VBOOKNAME"/>
<return-property name="AUTHOR" column="VAUTHOR"/>
<return-property name="PUBLICATION" column ="VPUBLICATION"/>
<return-property name="PRICE" column ="VPRICE"/>
</return>
EXECUTE PROCEDURE TESTSELECTSP
</sql-query>[/code]
The code ive written to call the stored procedure is:
[code]Dim NamedQuery As IQuery = Session.GetNamedQuery("_TESTSELECTSP")
Dim list As IList = NamedQuery.List [b]'Exception comes here[/b]
If list.Count <> 0 Then
MessageBox.Show("Done")
End If[/code]
I get an error:
Cannot execute query [ EXECUTE PROCEDURE TESTSELECTSP]
I get IndexOutOfrangeException
"Could not find specified column in results."
I am totally stuck with this problem:
Please help me get out of this hell problem!!!
Regards
_________________ Shanand Chandradas
|