首页 > 代码库 > Entity Framework

Entity Framework

https://msdn.microsoft.com/en-us/library/jj679962(v=vs.113).aspx

1.引用Entity Framework

技术分享

2.Data Annotations

  1)主键:[Key] 2.复合主键:多个[Key] 3.外键:[ForeignKey] 4.必须:[Required]

 

Entity Framework