It is totally possible to Insert Multiple Values into Multiple Tables in a Single Statement. Let us learn how we can do that in today’s SQL in Sixty Seconds video.
One of the most popular questions, I often receive from my client  Comprehensive Database Performance Health Check. I often see people implementing triggers for this scenario. However, you can easily do that if you use the OUTPUT clause efficiently. This is available for many years in SQL Server but I do not see many people using it.
In today’s quick video we will learn How to Insert Multiple Values into Multiple Tables in a Single Statement?
If you want to download the scripts and try out yourself, here is the link to the out blog post which contains them.
If you like my videos, I request you to like, share, comment, and subscribe to these videos. Here is the link to my YouTube Videos.
Here are my recent SQL in the Sixty Seconds:
- Nonclustered Primary Key – SQL in Sixty Seconds #119
- Recent Execution of Stored Procedure – SQL in Sixty Seconds #118
- Full-Screen Execution Plan – SQL in Sixty Seconds #117
- Recover Crashed Query in SSMS – SQL in Sixty Seconds #116
- Activity Monitor and Running Query – SQL in Sixty Seconds #115
- Email an Execution Plan – SQL in Sixty Seconds #114
- Execution Plan – Estimated vs Actual – SQL in Sixty Seconds #113
- Who Dropped Your Table? – SQL in Sixty Seconds #112
- Single Column Single Row and TABLE SCAN – SQL in Sixty Seconds #111
- Dirty Read with NOLOCK – SQL in Sixty Seconds #110
- Undo Human Errors in SQL Server – SQL in Sixty Seconds #109 – Point in Time Restore
- Solve Puzzle about Data type – SQL in Sixty Seconds #108
- Move TempDB for Performance – SQL in Sixty Seconds #107
- Do MAX(col) Scan Table? – SQL in Sixty Seconds #106
- Rollback TRUNCATE – Script – SQL in Sixty Seconds #105
Reference:Â Pinal Dave (https://blog.sqlauthority.com)