How to Execute Store Procedure with Asp.net in NHi
Dear Sir
We are using NHibernate with Asp.net.
I have written this code in HBM file
<sql-query name="OtherProfileAreas">
<return class="OtherProfileArea">
<return-property name="OtherDomain" column="OtherDomain"/>
<return-property name="Total" column="Total"/>
</return>
exec [dbo].[OtherProfileArea]
</sql-query>
</hibernate-mapping>
Also Created DAO for the same
now while executing the same
NHibernate.ISession iSession = NHibernateSessionManager.Instance.GetSessionFrom(S essionFactoryConfigPath);
NHibernate.IQuery query = iSession.GetNamedQuery("OtherProfileArea");
It gives run time error of
The given key was not present in the dictionary.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.Exception: The given key was not present in the dictionary.
|