I am new to EF.
When I used DbContext Generator
, it created separate partial classes for my entities.
Next I added a property to one of the classes e.g. To the Users
class I added a Phone
property
public partial class Users
{
public int UserId{get; set;}
/*new Property*/
public int Phone{get; set;}
}
But when I update the edmx, i.e. Update Model from Database, the new property is overwritten.
When I used Partial class instead of the DbContext Generator
, the new property is not overwritten.
So what is the use of using Dbcontext generator then?