Enums EF 5.0 - Database First

允我心安 提交于 2019-12-17 15:54:25

问题


How can I make it so that my context objects uses the Enum feature in Entity Framework 5.0 if I am using Database First.


回答1:


Go to the model browser and create a new enum type, then go to whatever column you wish to use it on and change its type to the enum that you just created.



来源:https://stackoverflow.com/questions/11595008/enums-ef-5-0-database-first

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!