DELETE Statements
Below is a sample SQL DELETE command. This command is used to remove one or more records from a database table.
DELETE
FROM categories
WHERE category_id=4
Note
- Without the WHERE clause, every record in the table would be deleted.
- There is no UNDO command on a database.
- The best WHERE clause is one that filters things based on a primary key, like song_id
- You can delete multiple records by using different WHERE clauses.