I am having some trouble getting merge replication working. I have 1 server
acting as a publisher and distributer and another server acting as my
subscriber. Both are running SQL 2000 SP4.
I need both the publisher and subscriber to be able to update the database.
One database is for internal company apps and the other is for our web
server both of which need access to the same database.
The steps are as follows.
1. Create a new publication using the "Create Publication Wizare" and using
all the defaults. When I come to the "Specify Articles" dialog I add my
table articles using the defaults and a few minor changes as follows:
- Keep the existing table unchanged.
- Automatically assign and maintain a unique range for each
subscription.
- Range size at pub = 10000
- Range size at sub = 10000
- Threshold = 90
2. I run the snapshot agent
3. I PUSH a new subscription using the "Push Subscription Wizard", using all
the defaults.
So far I have not gotten this to work at all. I get one of two major errors.
1. Violation of Primary Key constraint 'tablename'. Cannot insert duplicate
key in object 'tablename'
2. (If I select "Drop the existing table and re-create it" when adding
articles) I get an error complaining that the table cannot be dropped
because of a foreign key relationship (which it does have).
3. If I try and add any data at the subscriber I get an error telling me I
have to run Sp_adjustpublisheridentityrange.
What is the correct process here.
1) can we get more info on the primary key violation. Where does this show
up? Do you see it in the conflict viewer?
2) Ideally your subscriber would be an empty database when applying the
subscriber. Can you drop the problem table on the subscriber before
distributing the snapshot.
3) Check the table on the subscriber and drop the replication check
constraint on the identity column.
"Robert Sheppard" <sheprts@.cox.net> wrote in message
news:%23xX47jx5FHA.884@.TK2MSFTNGP14.phx.gbl...
>I am having some trouble getting merge replication working. I have 1 server
> acting as a publisher and distributer and another server acting as my
> subscriber. Both are running SQL 2000 SP4.
> I need both the publisher and subscriber to be able to update the
> database.
> One database is for internal company apps and the other is for our web
> server both of which need access to the same database.
> The steps are as follows.
> 1. Create a new publication using the "Create Publication Wizare" and
> using
> all the defaults. When I come to the "Specify Articles" dialog I add my
> table articles using the defaults and a few minor changes as follows:
> - Keep the existing table unchanged.
> - Automatically assign and maintain a unique range for each
> subscription.
> - Range size at pub = 10000
> - Range size at sub = 10000
> - Threshold = 90
> 2. I run the snapshot agent
> 3. I PUSH a new subscription using the "Push Subscription Wizard", using
> all
> the defaults.
> So far I have not gotten this to work at all. I get one of two major
> errors.
> 1. Violation of Primary Key constraint 'tablename'. Cannot insert
> duplicate
> key in object 'tablename'
> 2. (If I select "Drop the existing table and re-create it" when adding
> articles) I get an error complaining that the table cannot be dropped
> because of a foreign key relationship (which it does have).
> 3. If I try and add any data at the subscriber I get an error telling me I
> have to run Sp_adjustpublisheridentityrange.
> What is the correct process here.
>
>
Wednesday, March 7, 2012
Replication not updating the subscriber
Labels:
acting,
database,
distributer,
merge,
microsoft,
mysql,
oracle,
publisher,
replication,
server,
serveracting,
sql,
subscriber,
trouble,
updating,
working
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment