Метод ReplicationMonitor.EnumPublishers
Returns information on the Publishers that use the monitored Distributor.
Пространство имен: Microsoft.SqlServer.Replication
Сборка: Microsoft.SqlServer.Rmo (в Microsoft.SqlServer.Rmo.dll)
Синтаксис
'Декларация
Public Function EnumPublishers As DataSet
'Применение
Dim instance As ReplicationMonitor
Dim returnValue As DataSet
returnValue = instance.EnumPublishers()
public DataSet EnumPublishers()
public:
DataSet^ EnumPublishers()
member EnumPublishers : unit -> DataSet
public function EnumPublishers() : DataSet
Возвращаемое значение
Тип: System.Data.DataSet
A DataSet object that contains the following columns.
Column |
Data type |
Description |
---|---|---|
name |
Name of Publisher. |
|
distribution_db |
Distribution database for the specified Publisher. |
|
security_mode |
Security mode used by the replication agent in a push subscription to connect to the Publisher. |
|
login |
Login name used by the replication agent in a push subscription to connect to the Publisher. |
|
password |
Password returned (in simple encrypted form). Password is null for users other than sysadmin. |
|
active |
Whether a remote Publisher is using the local server as a Distributor: |
|
working_directory |
Name of the working directory. |
|
trusted |
If the password is required when the Publisher connects to the Distributor. For Microsoft SQL Server 2005, this should always return 0, which means that the password is required. |
|
thirdparty_flag |
Whether the publication is enabled by SQL Server or by a third-party application: false = Oracle, or Oracle Gateway Publisher. true = Publisher has been integrated with SQL Server using a third-party application. |
|
publisher_type |
Type of Publisher, which can be one of the following: MSSQLSERVER ORACLE ORACLE GATEWAY |
|
publisher_data_source |
Name of the OLE DB data source on the Publisher. |
Замечания
You should commit any property changes to the ReplicationMonitor object before calling this method because properties of this object may need to be loaded if they have not been loaded already.
If a Distributor is not installed or the distribution database is not created, this method throws an exception.
The EnumPublishers method can only be retrieved by members of the sysadmin fixed server role at the Distributor, by members of the db_owner or replmonitor fixed database role in the distribution database, or by users in the publication access list (PAL) of a publication that uses the Distributor.
Retrieving EnumPublishers is equivalent to executing Хранимая процедура sp_helpdistpublisher (Transact-SQL).
См. также
Справочник
Пространство имен Microsoft.SqlServer.Replication
Другие ресурсы
Наблюдение за репликацией программным образом (программирование объектов RMO)