sqlserver insert into
The "INSERT INTO" statement in SQL Server is used to insert a new row or multiple rows into a table. The basic syntax is:
INSERT INTO table_name (column1, column2, column3, ...)
VALUES (value1, value2, value3, ...);
Here, "table_name" is the name of the table into which you want to insert data. "column1", "column2", "column3", etc. are the names of the columns in the table. And "value1", "value2", "value3", etc. are the values you want to insert into those columns.
You can also insert multiple rows at once by specifying multiple sets of values separated by commas:
INSERT INTO table_name (column1, column2, column3, ...)
VALUES (value1a, value2a, value3a, ...),
(value1b, value2b, value3b, ...),
(value1c, value2c, value3c, ...);
Note that the number of columns and the number of values must match, and the data types of the values must match the data types of the columns
原文地址: https://www.cveoy.top/t/topic/g2fG 著作权归作者所有。请勿转载和采集!