ReplicationServer.UninstallDistributor Method
Uninstalls replication publishing and distribution on the currently connected instance of SQL Server.
Espacio de nombres: Microsoft.SqlServer.Replication
Ensamblado: Microsoft.SqlServer.Rmo (in microsoft.sqlserver.rmo.dll)
Sintaxis
'Declaración
Public Sub UninstallDistributor ( _
force As Boolean _
)
public void UninstallDistributor (
bool force
)
public:
void UninstallDistributor (
bool force
)
public void UninstallDistributor (
boolean force
)
public function UninstallDistributor (
force : boolean
)
Parámetros
- force
A Boolean value that specifies whether or not replication objects are removed from the server, even if a remote Distributor cannot be reached. If true, the publishing and Distributor configuration at the current server is uninstalled regardless of whether or not dependent publishing and distribution objects are uninstalled. If false, all dependent publishing and distribution objects are dropped before the Distributor is uninstalled.
Notas
Before calling UninstallDistributor, you must first perform the following tasks:
Delete all subscriptions. For more information, see How to: Delete a Push Subscription (RMO Programming) and How to: Delete a Pull Subscription (RMO Programming).
Delete all publications. For more information, see How to: Delete a Publication (RMO Programming).
Drop any distribution databases. For more information, see How to: Disable Publishing and Distribution (RMO Programming).
The UninstallDistributor method can only be called by members of the sysadmin fixed server role.
The UninstallDistributor method is equivalent to executing the sp_dropdistributor (Transact-SQL) stored procedure.
This namespace, class, or member is supported only in version 2.0 of the .NET Framework.
Ejemplo
myDist.UninstallDistributor(false);
Seguridad para subprocesos
Any public static (Shared in Microsoft Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
Plataformas
Plataformas de desarrollo
Para obtener una lista de las plataformas compatibles, vea Requisitos de hardware y software para instalar SQL Server 2005.
Plataformas de destino
Para obtener una lista de las plataformas compatibles, vea Requisitos de hardware y software para instalar SQL Server 2005.
Vea también
Referencia
ReplicationServer Class
ReplicationServer Members
Microsoft.SqlServer.Replication Namespace