I have 2 Entities User and User_Profile (one to one relationship). I have linked them as follows:
public class User { [Key] [ForeignKey(\"user_profile\"
You have to set the StoreGeneratedPattern attribute to Identity in your .edmx file to let the framework know the field is generated by the database. This link might help...
Autonumber with Entity Framework