Пример #1
0
        public void UpdateBook(Sach sach)
        {
            string query = "Update Sach Set TenSach=N'" + sach.TenSach + "', MaTheLoai=N'" + sach.TenTheLoai + "',SoLuong='" + sach.SoLuong + "',TenTacGia=N'" + sach.TenTacGia + "' Where MaSach='" + sach.MaSach + "' ";

            DataProvider.Instance.ExecuteNonQuery(query);
        }
Пример #2
0
        public void AddBook(Sach sach)
        {
            string query = "Insert Sach Values('" + sach.MaSach + "',N'" + sach.TenSach + "',N'" + sach.TenTheLoai + "','" + sach.SoLuong + "',N'" + sach.TenTacGia + "')";

            DataProvider.Instance.ExecuteNonQuery(query);
        }