Displays the status of trace flags.
DBCC TRACESTATUS ( trace# [ ,...n ] )
trace#
Is the number of the trace flag whose status will be displayed.
n
Is a placeholder that indicates multiple trace flags can be specified.
DBCC TRACESTATUS returns a column for the trace flag number and a column for the status, indicating whether the trace flag is ON (1) or OFF (0). To get status information for all trace flags currently turned on, specify - 1 for trace#.
To enable certain trace flags, use DBCC TRACEON. To disable trace flags, use DBCC TRACEOFF.
DBCC TRACESTATUS permissions default to any user.
This example displays the status of all currently enabled trace flags by specifying a value of -1.
DBCC TRACESTATUS(-1)
GO
This example displays the status of trace flags 2528 and 3205.
DBCC TRACESTATUS (2528, 3205)
GO