View the Extended Events Targets for Registered Packages


THIS TOPIC APPLIES TO:yesSQL Server (starting with 2014)yesAzure SQL DatabasenoAzure SQL Data Warehouse noParallel Data Warehouse

Before you create a SQL Server Extended Events session, it is useful to determine what Extended Events targets are available. This task involves using Query Editor in SQL Server Management Studio to perform the following procedure.

After the statements in this procedure finish, the Results tab of Query Editor displays the following two columns:

  • package_name

  • target_name

To view the Extended Events targets for registered packages using Query Editor

  • In Query Editor, issue the following statements.

    USE msdb  
    SELECT package_name, target_name  
    FROM sys.dm_xe_objects o  
    JOIN sys.dm_xe_packages p  
         ON o.package_guid = p.guid  
    WHERE o.object_type = 'target'  

See Also

SQL Server Extended Events Targets
sys.dm_xe_objects (Transact-SQL)
sys.dm_xe_packages (Transact-SQL)