I have the following records in the table student(see in fig 1).Code:protected void Page_Load(object sender, EventArgs e) { DataClassesDataContext dbsonia = new DataClassesDataContext(); student result = dbsonia.students.Single(p => p.roll == 1); result.Name = "S"; dbsonia.SubmitChanges(); }
I am trying to update the Name of student whose Roll no =1. But Record is not updated in the database,can somebody help me out.




Reply With Quote