Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All

sys.dm_broker_activated_tasks (Transact-SQL)

Applies To: SQL Server 2014, SQL Server 2016 Preview

Topic Status: Some information in this topic is preview and subject to change in future releases. Preview information describes new features or changes to existing features in Microsoft SQL Server 2016 Community Technology Preview 2 (CTP2).

Returns a row for each stored procedure activated by Service Broker.

Applies to: SQL Server (SQL Server 2008 through current version).

Column name

Data type

Description

spid

int

ID of the session of the activated stored procedure. NULLABLE.

database_id

smallint

ID of the database in which the queue is defined. NULLABLE.

queue_id

int

ID of the object of the queue for which the stored procedure was activated. NULLABLE.

procedure_name

nvarchar(650)

Name of the activated stored procedure. NULLABLE.

execute_as

int

ID of the user that the stored procedure runs as. NULLABLE.

Requires VIEW SERVER STATE permission on the server.

From

To

Relationship

dm_broker_activated_tasks.spid

dm_exec_sessions.session_id

One-to-one

Community Additions

ADD
Show:
© 2015 Microsoft