DML - DELETE

 

Used to remove whole rows from a table.  Use with caution!

 

Check the Personnel table before and after running each of the following DELETE statements.

 

 

Exercise:  Delete the Chemistry staff member from the Personnel table:

 

DELETE * FROM Personnel

WHERE Department = "Chemistry";

 

 

Exercise:  Delete all staff members (no conditions):

 

DELETE * FROM Personnel;

 

 

Syntax

 

DELETE * FROM tablename

WHERE criteria

 

NOTE:  MS Access requires the * to designate all columns; other databases use DELETE FROM ...