Insert multiple rows into a Microsoft SQL Server database

There is a great way to insert multiple rows into a Microsoft SQL Server database in one statement. This notation has multiple advantages: simplicity and the grouping of multiple instructions into one transaction.

INSERT MyTable (name, description)
VALUES
('John', 'Manager')
,('Bill', 'Truck driver')

Script from Ernie Cruz

Leave a comment

Your email address will not be published. Required fields are marked *