RIG000
چهارشنبه 08 آبان 1392, 18:17 عصر
من تو دیتابیسم فیلدی رو زیاد یا کم میکنم و از اونجایی که Databasefirs کار میکنم ...
باید موقعی که update model from database رو میزنم جدولامو بیاره .... تا اینجاش درست اما من همیشه میرم کلاسایی که بوده رو تغییر میدم...؟؟ حالا اگه table جدید داشته باشم که دیگه مجبورم برم از اول ado.net entity رو بسازم....
مثلا این اگه یه فیلد اضاف کنم باید بیام کلاسش رو دستی تغییر بدم؟؟؟
[CODE][ public partial class tblUser
{
public tblUser()
{
this.tblFactors = new HashSet<tblFactor>();
}
public int Id { get; set; }
public string Name { get; set; }
public string Lname { get; set; }
public string Email { get; set; }
public string Password { get; set; }
public string Province { get; set; }
public string City { get; set; }
public string Address { get; set; }
public string Mobile { get; set; }
public string Tell { get; set; }
public System.DateTime InsertDate { get; set; }
public virtual ICollection<tblFactor> tblFactors { get; set; }
}/CODE]
واگه یه تیبیل جدید تو دیتابیس بسازم چی؟ ؟؟؟؟؟
باید بیام کلاسش رو بسازم دستی؟
باید موقعی که update model from database رو میزنم جدولامو بیاره .... تا اینجاش درست اما من همیشه میرم کلاسایی که بوده رو تغییر میدم...؟؟ حالا اگه table جدید داشته باشم که دیگه مجبورم برم از اول ado.net entity رو بسازم....
مثلا این اگه یه فیلد اضاف کنم باید بیام کلاسش رو دستی تغییر بدم؟؟؟
[CODE][ public partial class tblUser
{
public tblUser()
{
this.tblFactors = new HashSet<tblFactor>();
}
public int Id { get; set; }
public string Name { get; set; }
public string Lname { get; set; }
public string Email { get; set; }
public string Password { get; set; }
public string Province { get; set; }
public string City { get; set; }
public string Address { get; set; }
public string Mobile { get; set; }
public string Tell { get; set; }
public System.DateTime InsertDate { get; set; }
public virtual ICollection<tblFactor> tblFactors { get; set; }
}/CODE]
واگه یه تیبیل جدید تو دیتابیس بسازم چی؟ ؟؟؟؟؟
باید بیام کلاسش رو بسازم دستی؟