NHibernate: How to set DynamicUpdate on all Entities?
问题 How can I set DynamicUpdate and DynamicInsert on all my entities? It works perfectly when I put it together with my mapping code, but I would like to specify it only once for my entire project. I could not find an option when creating the Session or in the Configuration. Any ideas? 回答1: I use fluent nhibernate so I would change them like this: var fluentConfiguration = Fluently.Configure(NHibernate.Cfg.Configuration().Configure()) .Mappings(m => m.FluentMappings .AddFromAssemblyOf<OrderMap>()