Psst! Check what courses we have in our offer, and get them all here to save $727. Tick-tock—this deal ends on 3/21.
Introduction
Inserting data
Modifying data
Deleting data
13. Delete all rows
CRUD

Instruction

Great! Now something a little bit scary—you can delete all rows from a table in one command. Just run the DELETE command with no WHERE condition.

DELETE FROM User; 

Caution: Be careful using this command on a real database!

Exercise

The owners finally decided on a single cuisine. They want to serve Creole dishes, so delete all the data from the Dish table to make room for new meals.

Stuck? Here's a hint!

Type:

DELETE FROM Dish;