SQL Server Profiler is a rich interface to
create and manage traces and analyze and replay trace results.
The
events are saved in a trace file
that can later be analyzed or used to replay a specific series of steps when trying to diagnose a problem.
We can do the following using SQL Server Profiler
- Create a trace
- Watch the trace results as the trace runs
- Store the trace results in a table
- Start, stop, pause, and modify the trace results as necessary
- Replay the trace results
Profiler is a graphical user interface to SQL Trace for monitoring T-SQL Statements of Database Engine.
We can save and reuse the state at a later point of time.
This section discusses those in addition to the base tracing capabilities.
Getting Started: Profiler[
^]
http://msdn.microsoft.com/en-us/library/ms181091.aspx[
^]
Monitoring with SQL Profiler[
^]
SQL Server Profiler Step by Step[
^]
Use SQL Profiler to:
- Monitor the performance of an instance of SQL Server.
- Debug Transact-SQL statements and stored procedures.
- Identify slow-executing queries.
- Test SQL statements and stored procedures in the development phase of a project by single-stepping through statements to confirm that the code works as expected.
- Troubleshoot problems in SQL Server by capturing events on a production system and replaying them on a test system. This is useful for testing or debugging purposes and allows users to continue using the production system without interference.
- Audit and review activity that occurred on an instance of SQL Server. This allows a security administrator to review any of the auditing events, including the success and failure of a login attempt and the success and failure of permissions in accessing statements and objects.