I’m so surprise while I’m working in Fluent NHibernate. I got my legacy database that has primary key column name is different from my property in domain model. I’m sure that I can use this mapping file:
<class name='Person'> <id name='Id' column='CommentId'> <generator class='native'/> </id> <property name='Description' type='String' /> </class>
But how I really get this mapping in Fluent NHibernate mapping?
The following Fluent-NHibernate mapping:
generates this XML mapping: