DML kya hota hai?

DML = table ke andar “rows/data” ko change karna.

Schema (structure) nahi badalta—sirf data badalta.

DML commands:

Must-know: DML usually transactional hota hai (COMMIT/ROLLBACK se control).


1) INSERT

1.1 Basic insert (single row)

INSERT INTO table_name(col1, col2, col3)
VALUES (v1, v2, v3);

1.2 Multiple rows insert (faster)

INSERT INTO table_name(col1, col2, col3)
VALUES (v1, v2, v3),
       (v4, v5, v6);

Real world: bulk inserts me yeh efficient hota hai.

1.3 Insert without column list (not recommended)

INSERT INTO student
VALUES (1,'Harsh',10);

Risk: table structure change hua to insert break ya wrong mapping.

1.4 NULL / DEFAULT / AUTO_INCREMENT behavior