Start SQL Profiler and select File > New Trace. Specify the events, columns, and filters you want in your trace.Start the trace and then stop it.Export the definition. … Save the trace file.
Which methods allow you to schedule a SQL trace?
Scheduling Traces by Using SQL Server Agent The best way to schedule traces is to use SQL Server Agent to start the trace and then specify a trace stop time by using the Transact-SQL stored procedure sp_trace_setstatus, or SQL Server Profiler.
How do I trace a query in SQL Server?
Once in SQL Server Profiler, start a new trace by going to File > New Trace… The “Connect to Server” dialog opens, where you select your SQL Server instance. Then click on Connect. The Trace Properties window will open.