How to capture Microsoft SQL events for diagnosing, deadlocks and performance issues.

Less than one minute read time.

Microsoft has deprecated SQL Profiler and now uses Extended Events for capturing and logging transactions.

To setup Extended Events:

1. In Microsoft SQL Server Management Studio, connect to SQL server.

2. Expand Management, Extended Events.

3. Right click on Sessions, and select New Session Wizard.

4. Using the wizard, enter in a Session Name.

5. Select a Template, most template are the same as Profiler templates.  For deadlock issues, select TSQL_Locks, for performance issues select Tuning.

6. The default fields and events will suffice for most instances.

7. In Section Specify Session Data Storage, Select to Save data to a file, keeping in mind the amount of space available.

8. When completed Extended Events will need to be started.