Using the TSQL OUTPUT Clause by Steve Stedman

Using the TSQL OUTPUT Clause by Steve Stedman

DBA-VUG

1 год назад

103 Просмотров

Title: Using the TSQL OUTPUT Clause

The OUTPUT clause is available on INSERT, DELETE, UPDATE, and MERGE statements is often times overlooked and not fully understood. Learn how to use the OUTPUT clause to log changes to an audit table. With the OUTPUT clause you can insert into two tables with a single transact SQL statement. The OUTPUT clause can be used with an INSERT statement to return the list of identities generated from the insert of multiple rows. Explore the performance of the OUTPUT clause with an INSERT, UPDATE, or DELETE statement compared to alternatives. Find out how to replace the standard use of SCOPE_IDENTITY, @@IDENTITY, or IDENT_CURRENT with the OUTPUT clause and much more.

ABOUT THE SPEAKER
Steve Stedman is a founder and owner of Stedman Solutions, LLC where he and the Stedman Solutions team do SQL Server database work ranging from SQL Server performance tuning and maintenance to programming and database corruption repair.
Steve has over 33 years of SQL Server experience working with SQL Server and other database platforms. He has written the book on SQL Common Table Expressions. In 2015 Steve created the Database Corruption Challenge, a weekly event to help DBAs be ready to react when they encounter corruption. Steve was the creator and has been the primary developer on Database Health Monitor for the last 12 years. He regularly blogs at http://SteveStedman.com.
Steve also gives back to the local community as a volunteer firefighter and EMT.

Тэги:

#TSQL_OUTPUT #tsql
Ссылки и html тэги не поддерживаются


Комментарии: