Re: t-slq/script replication question
- From: "Hilary Cotter" <hilary.cotter@xxxxxxxxx>
- Date: Fri, 6 Jan 2006 10:12:41 -0500
The GO statements have the effect of deallocating the variables you need to
declare and specify them again after each go statement or remove some of
your go statements.
--
Hilary Cotter
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Looking for a FAQ on Indexing Services/SQL FTS
http://www.indexserverfaq.com
"LPR-3rd" <lreames@xxxxxxxxx> wrote in message
news:1136560227.645311.113140@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
> When I run this script...
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> declare @location as char
> declare @pubname as char
> declare @SerVerName as char
> set @location = '03'
> set @pubname = 'EDI for #03'
> set @ServerName = 'ROUSE03SERVER'
>
> -- Enabling the replication database
> use master
> GO
>
> exec sp_replicationdboption @dbname = N'EDI_On_RouseMain', @optname =
> N'merge publish', @value = N'true'
> GO
>
> use [EDI_On_RouseMain]
> GO
>
> -- Adding the merge publication
> exec sp_addmergepublication @publication = @pubname, @description =
> N'Merge publication of EDI_On_RouseMain database from Publisher
> ROUSEMAIN.', @retention = 14, @sync_mode = N'native', @allow_push =
> N'true', @allow_pull = N'true', @allow_anonymous = N'true',
> @enabled_for_internet = N'false', @centralized_conflicts = N'true',
> @dynamic_filters = N'false', @snapshot_in_defaultfolder = N'true',
> @compress_snapshot = N'false', @ftp_port = 21, @ftp_login =
> N'anonymous', @conflict_retention = 14, @keep_partition_changes =
> N'true', @allow_subscription_copy = N'false', @allow_synctoalternate =
> N'false', @add_to_active_directory = N'false', @max_concurrent_merge =
> 0, @max_concurrent_dynamic_snapshots = 0
> exec sp_addpublication_snapshot @publication = @pubname,@frequency_type
> = 8, @frequency_interval = 64, @frequency_relative_interval = 0,
> @frequency_recurrence_factor = 1, @frequency_subday = 1,
> @frequency_subday_interval = 0, @active_start_date = 0,
> @active_end_date = 0, @active_start_time_of_day = 233400,
> @active_end_time_of_day = 0, @snapshot_job_name =
> N'ROUSEMAIN-EDI_On_RouseMain-EDI for #03-41'
> GO
>
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~`
> I receive the following message
>
> Server: Msg 137, Level 15, State 2, Line 3
> Must declare the variable '@pubname'.
> Server: Msg 137, Level 15, State 1, Line 4
> Must declare the variable '@pubname'.
>
>
> What am I missing??? What am I doing wrong??
>
> Larry...
>
.
- References:
- t-slq/script replication question
- From: LPR-3rd
- t-slq/script replication question
- Prev by Date: t-slq/script replication question
- Next by Date: Re: SQL 2000 - Replication and LDF file
- Previous by thread: t-slq/script replication question
- Next by thread: Re: t-slq/script replication question
- Index(es):
Relevant Pages
|