Click to Rate and Give Feedback
MSDN
MSDN Library
SQL Server
SQL Server 2008
Database Engine
Operations
Monitoring
 How to: View the Events for Registe...
Community Content
In this section
Statistics Annotations (0)
Collapse All/Expand All Collapse All
SQL Server 2008 Books Online (November 2009)
How to: View the Events for Registered Packages

Before you create a SQL Server Extended Events session, it is useful to find out what events are available in the registered packages. For more information, see SQL Server Extended Events Packages.

Accomplishing this task involves using Query Editor in SQL Server Management Studio to carry out the following procedure.

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

  • name . The package name.
  • event . The event name.
  • keyword . A keyword derived from an internal numeric mapping table.
  • channel . The audience for an event.
  • description . The event description.
  1. In Query Editor, issue the following statements.

    USE msdb
    SELECT p.name, c.event, k.keyword, c.channel, c.description FROM
    (
    SELECT event_package=o.package_guid, o.description, 
    event=c.object_name, channel=v.map_value
    FROM sys.dm_xe_objects o
    LEFT JOIN sys.dm_xe_object_columns c ON o.name=c.object_name
    INNER JOIN sys.dm_xe_map_values v ON c.type_name=v.name 
    AND c.column_value=cast(v.map_key AS nvarchar)
    WHERE object_type='event' AND (c.name='CHANNEL' or c.name IS NULL)
    
    ) c LEFT JOIN 
    (
    SELECT event_package=c.object_package_guid, event=c.object_name, 
    keyword=v.map_value
    FROM sys.dm_xe_object_columns c INNER JOIN sys.dm_xe_map_values v 
    ON c.type_name=v.name AND c.column_value=v.map_key 
    AND c.type_package_guid=v.object_package_guid
    INNER JOIN sys.dm_xe_objects o ON o.name=c.object_name 
    AND o.package_guid=c.object_package_guid
    WHERE object_type='event' AND c.name='KEYWORD' 
    ) k
    ON
    k.event_package=c.event_package AND (k.event=c.event or k.event IS NULL)
    INNER JOIN sys.dm_xe_packages p ON p.guid=c.event_package
    ORDER BY keyword desc, channel, event
Tags What's this?: Add a tag
Community Content   What is Community Content?
Add new content RSS  Annotations
Processing
© 2010 Microsoft Corporation. All rights reserved. Terms of Use | Trademarks | Privacy Statement
Page view tracker