Deals Of The Week - hours only!Up to 80% off on all courses and bundles.-Close
Introduction
Using CTEs with data-modifying statements
11. DELETE statement
Summary

Instruction

Great! It's time for the last data modification statement, DELETE. First, though, we will review the syntax of the DELETE statement. This statement is used to remove records from a table. Look at this example:

DELETE FROM customer
WHERE id = 15;

This statement starts with DELETE FROM, after which we give the name of the table (here, customer). In the WHERE clause, we specify which records to delete. In this query, the condition (id = 15) causes the removal of only one record, the one with the customer ID equals 15.

Exercise

Remove information for the store with the name of Small Grocery Store from the database.

Stuck? Here's a hint!

Use DELETE FROM ... WHERE ...