| title | sp_enum_proxy_for_subsystem (Transact-SQL) | Microsoft Docs | ||
|---|---|---|---|
| ms.custom | |||
| ms.date | 03/14/2017 | ||
| ms.prod | sql-non-specified | ||
| ms.reviewer | |||
| ms.suite | |||
| ms.technology |
|
||
| ms.tgt_pltfrm | |||
| ms.topic | language-reference | ||
| f1_keywords |
|
||
| dev_langs |
|
||
| helpviewer_keywords |
|
||
| ms.assetid | 580cc3be-1068-4a96-8d15-78ca3a5bb719 | ||
| caps.latest.revision | 27 | ||
| author | JennieHubbard | ||
| ms.author | jhubbard | ||
| manager | jhubbard |
[!INCLUDEtsql-appliesto-ss2008-xxxx-xxxx-xxx_md]
Lists permissions for [!INCLUDEssNoVersion] Agent proxies to access subsystems.
| Applies to: [!INCLUDEssNoVersion] ([!INCLUDEssKatmai] through current version). |
Transact-SQL Syntax Conventions
sp_enum_proxy_for_subsystem
[ @proxy_id = ] proxy_id,
[ @proxy_name = ] 'proxy_name',
[ @subsystem_id = ] subsystem_id,
[ @subsystem_name = ] 'subsystem_name'
[ @proxy_id = ] proxy_id
The identification number of the proxy to list information for. The proxy_id is int, with a default of NULL. Either the id or the proxy_name may be specified.
[ @proxy_name = ] 'proxy_name'
The name of the proxy to list information for. The proxy_name is sysname, with a default of NULL. Either the id or the proxy_name may be specified.
[ @subsystem_id = ] subsystem_id
The identification number of the subsystem to list information for. The subsystem_id is int, with a default of NULL. Either the subsystem_id or the subsystem_name may be specified.
[ @subsystem_name = ] 'subsystem_name'
The name of the subsystem to list information for. The subsystem_name is sysname, with a default of NULL. Either the subsystem_id or the subsystem_name may be specified.
0 (success) or 1 (failure)
| Column name | Data type | Description |
|---|---|---|
| subsystem_id | int | Subsystem identification number. |
| subsystem_name | sysname | The name of the subsystem. |
| proxy_id | int | Proxy identification number. |
| proxy_name | sysname | The name of the proxy. |
When no parameters are provided, sp_enum_proxy_for_subsystem lists information about all proxies in the instance for every subsystem.
When a proxy id or proxy name is provided, sp_enum_proxy_for_subsystem lists subsystems that the proxy has access to. When a subsystem id or subsystem name is provided, sp_enum_proxy_for_subsystem lists proxies that have access to that subsystem.
When both proxy information and subsystem information is provided, the result set returns a row if the proxy specified has access to the subsystem specified.
This stored procedure is located in msdb.
Execution permissions for this procedure default to members of the sysadmin fixed server role.
The following example lists all permissions established between proxies and subsystems for the current instance.
USE msdb ;
GO
EXEC dbo.sp_enum_proxy_for_subsystem ;
GO
The following example returns a row if the proxy Catalog application proxy has access to the ActiveScripting subsystem. Otherwise, the example returns an empty result set.
USE msdb ;
GO
EXEC dbo.sp_enum_proxy_for_subsystem
@subsystem_name = 'ActiveScripting',
@proxy_name = 'Catalog application proxy' ;
GO