How do you map an enum as an int value with fluent NHibernate?

后端 未结 7 2009
迷失自我
迷失自我 2020-11-27 11:04

Question says it all really, the default is for it to map as a string but I need it to map as an int.

I\'m currently using Persistenc

7条回答
  •  生来不讨喜
    2020-11-27 11:25

    You could create an NHibernate IUserType, and specify it using CustomTypeIs() on the property map.

提交回复
热议问题