#1 Data Analytics Program in India
₹2,499₹1,499Enroll Now
Step 4
3 min read

DELETE Operations

Learn how to safely remove data from your database tables.

What is DELETE?

DELETE removes rows from a table. Like removing a contact from your phone - the contact is gone but your phone still works.

How DELETE Works

Step-by-step:

  1. DELETE FROM students - Target the students table
  2. WHERE id = 3 - Find the row where id equals 3
  3. Remove - That row is permanently deleted
  4. Result - Table structure stays, only data removed

Basic Syntax

DELETE FROM table_name WHERE condition;

DANGER: Always Use WHERE!

-- DANGEROUS - Deletes ALL rows! DELETE FROM students; -- SAFE - Deletes only one row DELETE FROM students WHERE id = 3;

Try DELETE Below

Use the playground to practice DELETE queries. Try:

  • DELETE FROM students WHERE id = 3;
  • DELETE FROM students WHERE grade = 'B';

What Comes Next

You completed Step 4! You now know SELECT, INSERT, UPDATE, and DELETE.

Next: Learn WHERE clause for filtering data.

Try DELETE

Remove rows from the table using WHERE conditions

Current Table: students
idnameagegrade
1Alice20A
2Bob22B
3Charlie21A
4David23B
4 rows
SQL Editor
Loading...

Finished this topic?

Mark it complete to track your progress and maintain your streak!

SkillsetMaster - AI, Web Development & Data Analytics Courses