1.DataBase:SqlServer 2.Data Access:nHibernate 1.2
Now we need access the store procedure by nHibernate,like this: ALTER PROCEDURE [dbo].[TestProc]() AS BEGIN Select * From User Return 1234 END I know I can get the User List by IQuery, And I want to get the default value "1234" too.
Question: 1.How to get this default return value? 2.If can't get it directly , can we get the value by output parameter?
=================================================== 1.数据库:SqlServer 2.数据访问:nHibernate 1.2
现在需要用nHibernate访问数据库中的一个存储过程,类似如下: ALTER PROCEDURE [dbo].[TestProc]() AS BEGIN Select * From User Return 1234 END 我知道可以IQuery对象访问该存储过程,得到这个User List, 但我现在除了想得到这个UserList 之外,还想得到我设定的返回值 "1234"
问题: 1.这个返回值是应该如何得到呢? 2.如果这个返回值不能直接获得,能否给存储过程添加output参数获得?如何获得?
|