SQL Tutorial – Delete specific records from a table.

Spread the love

You want to delete records from a table that meets some specific criterion. For example, you want to delete all the rows which has null values in the christmas_spending column.

Solution –

We can use the DELETE command with WHERE clause to delete specific records from a table.

 DELETE FROM actors_info
 WHERE christmas_spending IS NULL 

Before you delete any data, please make sure that you are deleting the right data by using the WHERE clause with the SELECT statement

 SELECT * FROM actors_info
 WHERE christmas_spending IS NULL 

Rating: 1 out of 5.

Leave a Reply