I am getting exception when calling Stored Procedure using Nhibernate and here is the exception
No persister for: ReleaseDAL.ProgressBars, ReleaseDAL, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null
here is class file
public class ProgressBars
{
public ProgressBars()
{ }
private Int32 _Tot;
private Int32 _subtot;
public virtual Int32 Tot {get { return _Tot; } set { _Tot = value; } }
public virtual Int32 subtot { get { return _subtot; } set { _subtot = value; }}
}
here is my mapping file
<hibernate-mapping xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="urn:nhibernate-mapping-2.2"
assembly="ReleaseDAL" namespace="ReleaseDAL" >
<sql-query name="ps_getProgressBarData1" >
<return alias="ProgressBars" class="ProgressBars">
<return-property name="Tot" column="Tot"/>
<return-property name="subtot" column="subtot"/>
</return>
exec ps_getProgressBarData1
</sql-query>
</hibernate-mapping>
Calling Code
public List<ProgressBars> getProgressBarData1(Guid ReleaseId)
{
ISession session = NHibernateHelper.GetCurrentSession();
List< ProgressBars> progressBar = (List<ProgressBars>)session.GetNamedQuery("ps_getProgressBarData1").List<ProgressBars>();
NHibernateHelper.CloseSession();
return progressBar;
}
here is my output column from stored procedure
its Tot,subtot
I am introuble due to this exception, I did lot Google but no success, Please give idea to solve this problem.
Thanks.........