profiler
#profiler#create-a-t-sql-script-for-running-a-trace

Create a T-SQL Script for Running a Trace

06/06/2025 This article describes how to create a Transact-SQL script from an existing trace file or table by using SQL Server Profiler. 1. Open

This article describes how to create a Transact-SQL script from an existing trace file or table by

using SQL Server Profiler.

  1. Open a trace file or table. For more information, see

Open a trace file (SQL Server Profiler)

or

Open a trace table (SQL Server Profiler).

  1. On the

menu, point to

, point to

, and then select the

version that corresponds to the server you want to trace.

  1. In the

dialog box, enter a name for the script file, and then select.

Profiler templates and permissions

Profiler