SQL Server Performance

Disabling merge replication agents

Discussion in 'Performance Tuning for SQL Server Replication' started by Lesleyg, Nov 9, 2004.

  1. Lesleyg New Member

    Hi folks,

    I have a large number of merge replication agents that I need to disable. Rather than using Enterprise Mananger to disable each one in turn, can anyone suggest a quicker method of doing this?

    thanks,
    LesleyG
  2. vbkenya New Member

    If you are ready for some programming, you can try out the SQLDMO Jobs collection or jump straight into the SQL Merge Control



    Dim oJob as Job

    For each oJob in YourServer.Jobs
    '// if this job meets some particular criteria
    '//Insert logic here for checking if this job should be disabled

    oJob.Stop

    Next




    Nathan H.O.
    Moderator
    SQL-Server-Performance.com
  3. vbkenya New Member

Share This Page