MySQL Tutorial - INSERT - Add Data
โ INSERT - Data Add Karo
๐ Real Life:
๐ Form Submission:
Signup form bhara โ Database mein entry
New product add โ Products table mein insert
๐ฑ WhatsApp:
New contact save โ Contacts table
Syntax
INSERT INTO table_name (columns)
VALUES (values);
Examples
-- Single row
INSERT INTO students (name, age, class)
VALUES ('Rohan', 15, '10th');
-- Multiple rows
INSERT INTO students VALUES
(1, 'Simran', 16, '11th'),
(2, 'Amit', 15, '10th');
Example
INSERT INTO students (name, age)
VALUES ('Rohan', 20);