Loading Data Driven Insights
Preparing your learning content.
Preparing your learning content.
A beginner-friendly guide to the SQL INSERT statement, including basic syntax, inserting a new row, and checking the updated table.
The INSERT statement is used to add new rows into a table.
You use it when you want to store a new record in your database, such as a new employee, customer, order, product, or transaction.
The basic structure uses INSERT INTO to choose the table and columns, then VALUES to provide the data.
INSERT INTO table_name (
column1,
column2,
column3
)
VALUES (
value1,
value2,
value3
);
INSERT INTO Employees (
employee_id,
employee_name,
department,
salary
)
VALUES (
5,
'Sophia Clark',
'Finance',
48000
);
We will use the Employees table and add one new employee using INSERT.
The following query inserts one new row into the Employees table.
INSERT INTO Employees (
employee_id,
employee_name,
department,
salary
)
VALUES (
5,
'Sophia Clark',
'Finance',
48000
);
After the insert runs successfully, the new employee appears as a new row in the table.
Always make sure the selected columns and supplied values match in the correct order.
Learning SQL in order?
Use the roadmap to follow each SQL topic step by step, from relational database basics to advanced query techniques.
Back to SQL RoadmapRelated lessons
ALTER TABLE
A beginner-friendly guide to ALTER TABLE in SQL, including how to add, change, and remove columns from an existing table.
CREATE TABLE
A beginner-friendly guide to the SQL CREATE TABLE statement, including table planning, column names, data types, and a SQL Server-friendly example.
DELETE
A beginner-friendly guide to the SQL DELETE statement, with SQL Server-friendly examples for removing rows from a table safely.