Tags: NHibernate

Inserting Parent Child records using NHibernate IDENTITY INSERT OFF

NHibernate Benjamin Perkins

One of the errors I received when I was trying to get the parent child insert to work with NHibernate was: Ein expliziter Wert für die Identitätsspalte kann nicht in der ‘CHILD’-Tabelle eingefügt werden, wenn IDENTITY_INSERT auf OFF festgelegt ist Cannot insert explicit value for identity column in table ‘IdentityTable’ when IDENTITY_INSERT is set to […]

Read More →

Using NuGet to install your ORM into Visual Studio

Visual Studio Benjamin Perkins

I have spent a lot of time Working with NHibernate 3.0 and now am also giving some attention to the Entity Framework. One of the road blocks for using NHibernate is the initial configuration requirements. There are a significant number of actions which must be taken to get NHibernate working, where as, the Entity Framework […]

Read More →

NHibernate MappingException could not compile mapping document

NHibernate Benjamin Perkins

This is a fairly common error message which a programmer will receive during the NHibernate mapping process. The inner exception was: {“persistent class NAMESPACE.CLASSNAME, NAMESPACE not found”} {“Could not compile the mapping document: NAMESPACE.CLASSNAME.hbm.xml”} The root cause of this error was that the class (class.cs) existed in the NAMESPACE.Common namespace and in my mapping file […]

Read More →