通过流利的 nhibernate,我不能使用带有约定的自动映射,因为它为关系表添加了额外的外键。该问题已在stackoverflow.com/questions/6091654/fluentnhibernate-automapping-onetomany-relation-using-attribute-and-convention/7867516详细解释
但是正如你所看到的,它是通过使用属性来解决的。我的问题是:
我不想在 Model Properties 上使用属性。因为在接下来的几年里,我们可能不会在项目中使用 nhibernate。所以我不想碰模特。没有 KeyColumnAttribute 的问题是否有解决方案。
谢谢