Delete#
Syntax#
DELETE FROM table_name
WHERE predicate [AND predicate ...];
Rules#
WHEREis required. ADELETEwithout aWHEREclause is rejected by the parser.Predicates are combined with
ANDonly.
Examples#
Delete a specific row:
DELETE FROM new_order
WHERE no_w_id = 1 AND no_d_id = 2 AND no_o_id = 100;
Delete with placeholders:
DELETE FROM history
WHERE h_c_id = ? AND h_c_d_id = ? AND h_c_w_id = ?;