Quantcast
Channel: SQL Server Replication forum
Viewing all articles
Browse latest Browse all 4054

How to programatically stop/start Replication Local-Publication Snapshot agent after changing Publication configuration

$
0
0

I need to programmatically or via Powershell or TSQL stop and start a replication transactional snapshot agent after changing a publication configuration.

Config change below:-

USE [POS]
EXEC sp_changepublication
  @publication = N'IN_STORE',
  @property = N'snapshot_in_defaultfolder',
  @value = N'false'
GO


EXEC sp_changepublication
  @publication = N'IN_STORE',
  @property = N'alt_snapshot_folder',
  @value = N'C:\Program Files\POS\SqlSnapshots'
GO


Viewing all articles
Browse latest Browse all 4054

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>