By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,165 Members | 849 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,165 IT Pros & Developers. It's quick & easy.

nHibernate mapping exception

P: n/a
Hello All,
I am new to hibernate and new to nHibernate. I created a small app and
when i try and run it i get the error i posted at the bottom of this
message. I am using the helper class that can be found here
http://blogs.intesoft.net/simon/articles/16.aspx#36 . Does anyone know
why this error might occur.. i have NO IDEA.... if you require anymore
information please let me know and i will send it through.
Thanks in advance!
Erin

Server Error in '/test/nHibernateTest' Application.
--------------------------------------------------------------------------------

Unknown entity class:
nHibernateTest.Persistence.nHibernate.SharepointOb jectTitles
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: NHibernate.MappingException: Unknown entity class:
nHibernateTest.Persistence.nHibernate.SharepointOb jectTitles

Source Error:
Line 149: public static void Load(System.Type type, object id)
Line 150: {
Line 151: Database.Session.Load(type, id);
Line 152: }
Line 153:
Source File:
c:\inetpub\wwwroot\test\nhibernatetest\nhibernateh elper\database.cs
Line: 151

Stack Trace:
[MappingException: Unknown entity class:
nHibernateTest.Persistence.nHibernate.SharepointOb jectTitles]
NHibernate.Impl.SessionFactoryImpl.GetPersister(Ty pe theClass)
NHibernate.Impl.SessionImpl.GetClassPersister(Type theClass)
NHibernate.Impl.SessionImpl.DoLoadByClass(Type clazz, Object id,
Boolean checkDeleted, Boolean allowProxyCreation)
NHibernate.Impl.SessionImpl.Load(Type clazz, Object id)
nHibernateTest.NHibernateHelper.Database.Load(Type type, Object id)
in
c:\inetpub\wwwroot\test\nhibernatetest\nhibernateh elper\database.cs:151
nHibernateTest.nHibernateTest.Page_Load(Object sender, EventArgs e)
in c:\inetpub\wwwroot\test\nhibernatetest\nhibernatet est.aspx.cs:29
System.Web.UI.Control.OnLoad(EventArgs e)
System.Web.UI.Control.LoadRecursive()
System.Web.UI.Page.ProcessRequestMain()

Apr 11 '06 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Erin,

Try to get your answer from this forum:
http://forum.hibernate.org/viewforum.php?f=25

Cheers,
kids

er************@cowaninsurancegroup.com wrote:
Hello All,
I am new to hibernate and new to nHibernate. I created a small app and
when i try and run it i get the error i posted at the bottom of this
message. I am using the helper class that can be found here
http://blogs.intesoft.net/simon/articles/16.aspx#36 . Does anyone know
why this error might occur.. i have NO IDEA.... if you require anymore
information please let me know and i will send it through.
Thanks in advance!
Erin

Server Error in '/test/nHibernateTest' Application.
--------------------------------------------------------------------------------

Unknown entity class:
nHibernateTest.Persistence.nHibernate.SharepointOb jectTitles
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: NHibernate.MappingException: Unknown entity class:
nHibernateTest.Persistence.nHibernate.SharepointOb jectTitles

Source Error:
Line 149: public static void Load(System.Type type, object id)
Line 150: {
Line 151: Database.Session.Load(type, id);
Line 152: }
Line 153:
Source File:
c:\inetpub\wwwroot\test\nhibernatetest\nhibernateh elper\database.cs
Line: 151

Stack Trace:
[MappingException: Unknown entity class:
nHibernateTest.Persistence.nHibernate.SharepointOb jectTitles]
NHibernate.Impl.SessionFactoryImpl.GetPersister(Ty pe theClass)
NHibernate.Impl.SessionImpl.GetClassPersister(Type theClass)
NHibernate.Impl.SessionImpl.DoLoadByClass(Type clazz, Object id,
Boolean checkDeleted, Boolean allowProxyCreation)
NHibernate.Impl.SessionImpl.Load(Type clazz, Object id)
nHibernateTest.NHibernateHelper.Database.Load(Type type, Object id)
in
c:\inetpub\wwwroot\test\nhibernatetest\nhibernateh elper\database.cs:151
nHibernateTest.nHibernateTest.Page_Load(Object sender, EventArgs e)
in c:\inetpub\wwwroot\test\nhibernatetest\nhibernatet est.aspx.cs:29
System.Web.UI.Control.OnLoad(EventArgs e)
System.Web.UI.Control.LoadRecursive()
System.Web.UI.Page.ProcessRequestMain()

Apr 12 '06 #2

This discussion thread is closed

Replies have been disabled for this discussion.