DML Command in SQL

DML stands for Data Manipulation Language. It is a subset of SQL commands that allows you to modify the data in a database. You can use DML commands to insert, update, delete, and select data from tables. Here are some examples of DML commands in SQL:

  1. Insert
  2. Update
  3. Delete

INSERT: This command adds new records to a table. For example, if you want to insert a new record into the student table, you can write:

	INSERT INTO student (id, name, marks) VALUES (101, 'Raj', 85);

UPDATE: This command modifies existing records in a table. For example, if you want to update the marks of Raj in the student table, you can write:

		UPDATE student SET marks = 90 WHERE id = 101;

DELETE: This command removes records from a table. For example, if you want to delete the record of Raj from the student table, you can write:

DELETE FROM student WHERE id = 101;
Scroll to Top