all groups > sql server replication > february 2004 >
You're in the

sql server replication

group:

Scripting Replication


Scripting Replication Andrea Worley
2/27/2004 10:51:06 AM
sql server replication: I have to break and restart replication and I wanted to try and start it up again with a script. Is it as easy as just running "Generate SQL Script" and then running the script? I know I want to script the option "Enable or create the components" but do I also want the option "Script creation of replication jobs"? What's the difference

Re: Scripting Replication Narayana Vyas Kondreddi
2/29/2004 7:41:48 PM
Yes, the purpose of the scripting feature in Enterprise Manager is to enable
you to recreate a replication topology. I generally do not select the option
to 'script jobs' as the jobs get created anyway, when you create your
publications and subscriptions using the scripts.

By default, the scripts resetup the subscriptions, that is recreate the
tables on the subscription databases. But if you want to just subscribe with
NOSYNC option, you will have to slightly edit your scripts.
--
HTH,
Vyas, MVP (SQL Server)
http://vyaskn.tripod.com/
Is .NET important for a database professional?
http://vyaskn.tripod.com/poll.htm




[quoted text, click to view]
I have to break and restart replication and I wanted to try and start it up
again with a script. Is it as easy as just running "Generate SQL Script"
and then running the script? I know I want to script the option "Enable or
create the components" but do I also want the option "Script creation of
replication jobs"? What's the difference?

Thank you.

Re: Scripting Replication Paul Ibison
2/29/2004 8:42:42 PM
Andrea,

These options exist on the replication folder where you have the option of
setting up things from scratch - ie there is an implied posibility that
there might be no current replication setup on the server where you plan to
run the scripts. Firstly, if you choose to script the jobs or not, jobs will
be created to run the agents involved. However, if you do select to script
the jobs, then the miscellaneous agents will be created (eg Distribution
Cleanup agent) which are essential to the normal running of replication,
unless you want to create your own housecleaning routines or unless they
already have been setup. Also, if you choose to script the jobs, the script
required to reproduce your existing job will be created. This may be
different to the default one created as you typically want to customise the
schedule, and in many cases add parameters which don't exist on the profile
(eg -HOSTNAME in the case of the merge agent's merge job). BTW, there's no
problem in running the complete script (with the jobs) as each miscellaneous
agent is checked for existence before being created.

Regards,
Paul Ibison



[quoted text, click to view]
up again with a script. Is it as easy as just running "Generate SQL Script"
and then running the script? I know I want to script the option "Enable or
create the components" but do I also want the option "Script creation of
replication jobs"? What's the difference?
[quoted text, click to view]

Re: Scripting Replication Andrea Worley
3/1/2004 2:21:11 PM
AddThis Social Bookmark Button