tried to use the inheritance mapping. I get an error for each when a try to create a new FACTORY. I use the example from documentation with the entity map looking like
<Entity type="Domain:Company" table="Company" discriminator-field="Type"
discriminator-value="Company">
<Id field="CompanyId">
<Generator name="guid" />
</Id>
<Attribute name="Name" field="Name" db-type="String"/>
<Attribute name="SiretNb" field="SiretNb" db-type="Int32"/>
</Entity>
<Entity type="Domain:Factory" table="Company"
discriminator-field="Type"
discriminator-value="Factory" >
<Id field="CompanyId">
<Generator name="guid" />
</Id>
<Attribute name="City" field=" City " db-type="String"/>
</Entity>
I checked the query which looks like:
INSERT INTO [Company] ([CompanyId] , [ City ] , [Name] , [SiretNb] ) VALUES ( @EntityId , @ City , @Name , @SiretNb )
The parameters inside look fine and have the correct values. It happens only when I try to save values for derived class. Tried the same thing for the company class and works fine.
Thank you Cristian
btw I like your work