Beispiel #1
0
 public bool Sua(GiaoVien gv)
 {
     try
     {
         string query = @" UPDATE dbo.GiaoVien SET Ten = N'" + gv.Ten + "', GioiTinh = N'" + gv.GioiTinh + "',sodt = '" + gv.SoDT + "', diachi = N'" + gv.DiaChi + "',ngaysinh = '" + gv.NgaySinh + "', luong = '" + gv.Luong + "' where magv = '" + gv.MaGV + "'";
         OpenConection();
         ExecuteQueries(query);
         CloseConnection();
         return true;
     }
     catch (Exception ex)
     {
         SetEx(ex);
         return false;
     }
 }
 partial void UpdateGiaoVien(GiaoVien instance);
 partial void DeleteGiaoVien(GiaoVien instance);
 partial void InsertGiaoVien(GiaoVien instance);