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

  1. Without the WHERE clause, every record in the table would be deleted.
  2. There is no UNDO command on a database.
  3. The best WHERE clause is one that filters things based on a primary key, like song_id
  4. You can delete multiple records by using different WHERE clauses.