Is it possible to put a string in Unique Key ?
public int ID{ get; set; }
public string TweetID { get; set; }
Because I need ID in primary key (it's ok) and TweetID in unique key (for no duplication in database)
EDI开发者_如何学运维T : I use Entity Framework 4 and MVC3
It is possible to define unique key on string column but you must do it in the database (as unique index) because none of current EF versions support unique keys.
精彩评论