当前位置: 动力学知识库 > 问答 > 编程问答 >

database migration - DataAnnotation Atributes not applied in EF7

问题描述:

When i migrate a database using k ef migration add bla bla. command the data annotation attributes are not reflected to the created database

e.g. iam using the [MaxLength(2)] attribute and am getting a column with data type nvarchar(MAX) created

Any help please

网友答案:

Data Annotations are not yet implemented in EF7. See issue #107.

分享给朋友:
您可能感兴趣的文章:
随机阅读: