Skip to content

Latest commit

 

History

History
37 lines (30 loc) · 1.64 KB

File metadata and controls

37 lines (30 loc) · 1.64 KB
title Create a Transact-SQL Script for Running a Trace (SQL Server Profiler) | Microsoft Docs
ms.custom
ms.date 03/01/2017
ms.prod sql-server-2016
ms.reviewer
ms.suite
ms.technology
database-engine
ms.tgt_pltfrm
ms.topic article
helpviewer_keywords
traces [SQL Server], running
scripts [SQL Server], traces
ms.assetid 6b0e2519-998d-40d5-b8ba-5e6a773f91a6
caps.latest.revision 25
author JennieHubbard
ms.author jhubbard
manager jhubbard
ms.workload Inactive

Create a Transact-SQL Script for Running a Trace (SQL Server Profiler)

This topic describes how to create a Transact-SQL script from an existing trace file or table by using [!INCLUDEssSqlProfiler].

To create a Transact-SQL script to run a trace

  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).

  2. On theFilemenu, point to Export, point to Script Trace Definition, and then click the version that corresponds to the server you want to trace.

  3. In the Save As dialog box, enter a name for the script file, and then click Save.

See Also

SQL Server Profiler Templates and Permissions
SQL Server Profiler