Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

Start SnapShot agent in T-SQL Expand / Collapse
Author
Message
Posted Tuesday, July 11, 2006 7:23 AM
Old Hand

Old HandOld HandOld HandOld HandOld HandOld HandOld HandOld Hand

Group: General Forum Members
Last Login: Friday, August 2, 2013 7:04 AM
Points: 374, Visits: 408

SQL2005

 

I need to automate the starting of the snapshot agent.  At the moment i have to go into replication monitor right click on snapshot agent and click start.

Is this possible in T-SQL or do you have to use the DOS cmd. Any sample code would be nice,

Thanks,

Jules



www.sql-library.com
Post #293452
Posted Wednesday, July 12, 2006 11:59 AM


SSC Veteran

SSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC Veteran

Group: General Forum Members
Last Login: Thursday, December 5, 2013 12:21 PM
Points: 265, Visits: 164
I am not sure..but you can always run profiler and see whats being called..

******************
Dinakar Nethi
Life is short. Enjoy it.
******************
Post #293861
Posted Wednesday, July 12, 2006 1:45 PM
SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Wednesday, February 4, 2009 1:49 PM
Points: 160, Visits: 140

Every time the you create a publication a jobs is created in sql server with this name

[SERVER_NAME]-[DATABASE_NAME]-publ_[PUBL_NAME]

don't you have it on you job list ?

there is an step inside the job that look like this

 

-Publisher [SQL05] -PublisherDB [db_1] -Distributor [SQL05] -Publication [publ_db_1] -ReplicationType 2 -DistributorSecurityMode 1



Pedro R. Lopez
http://madurosfritos.blogspot.com/
Post #293903
Posted Saturday, December 10, 2011 11:18 AM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Friday, June 29, 2012 3:11 AM
Points: 3, Visits: 29
In Sql Server 2005, you can use the sp_startpublication_snapshot stored procedure to achieve this, using the following format:

sp_startpublication_snapshot [ @publication = ] 'publication'
[ , [ @publisher = ] 'publisher' ]

(omit the publisher out if you are using a SQL Server publisher).

I do not know if this is appropriate to Sql Server 7 or 2000 though.
Post #1219842
Posted Wednesday, April 2, 2014 10:33 AM


SSC Veteran

SSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC Veteran

Group: General Forum Members
Last Login: Wednesday, August 13, 2014 7:06 AM
Points: 211, Visits: 1,109

What about to call for distribution agent in Push Down subscription (snapshot replication) - which job to execute?

and the syntax listed in Job is not of Tsql SP? So how to manage both .. if we can call with the help of SP and with the help of Job syntax?

Thank you!

Post #1557595
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse