public void UpdateRow(int id, string column, string value) { string sql = $"UPDATE \"Order\" SET \"{column}\" = \'{value}\' WHERE \"OrderID\" = {id}"; CommonDAO.ExecuteNonQuery(sql); }
public void CreateNewRow(Order order) { string sql = $"INSERT INTO \"Order\" (\"CustomerID\", \"LoginName\", \"ProductID\", \"TotalSum\") VALUES ({order.CustomerID},{order.ProductID}, {order.TotalSum})"; CommonDAO.ExecuteNonQuery(sql); }
public void DeleteRow(int id) { string sql = $"DELETE FROM \"Order\" WHERE \"OrderID\" = {id}"; CommonDAO.ExecuteNonQuery(sql); }
public void CreateNewRow(Account account) { string sql = $"INSERT INTO \"Account\" (\"CustomerID\", \"LoginName\", \"Password\", \"Email\") VALUES ({account.CustomerID},{account.Login}, {account.Password}, {account.Email})"; CommonDAO.ExecuteNonQuery(sql); }