Groups | Blog | Home
all groups > sql server replication > august 2005 >

sql server replication : Merge replication problem


Chris Winstone
8/26/2005 3:19:01 AM
I am having a problem with sp_MSfetchidentityrange in a merge replication
with one subscriber.

The merge agent history shows the following 4 errors after executing the
last command: exec sp_MSfetchidentityrange N'Capacity_Type', 0

exec sp_MSadd_merge_history 32, 6, N'The merge process could not retrieve
identity range resource for table ''Capacity_Type''
and....

exec sp_MSadd_repl_error 2309, 0, 8, N'Merge Replication Provider',
'-2147200969', N'The merge process could not retrieve identity range resource
for table ''Capacity_Type''.'

and....
exec sp_MSadd_repl_error 2309, 0, 1, N'ABDN-SQL\OSLDB', '0', N'{call
sp_MSfetchidentityrange(?, 0) }'

and...
exec sp_MSadd_repl_error 2309, 0, 5, N'ABDN-SQL\OSLDB', '21195', N'A valid
identity range is not available. Check the data type of the identity column.'

The strange thing is that 12 other articles (before 'Capacity_Type) have
been replicated ok.

I.e. in a trace log you might see a run of successfull commands being
executed...

Step 1: exec sp_MSfetchidentityrange N'Thrusters', 0
Step 2: exec sp_MSfetchidentityrange N'Capacities', 0
Step 3: exec sp_MSfetchidentityrange N'Engines', 0
Step 4: exec sp_MSfetchidentityrange N'Towing', 0
Etc, etc

After I found this I thought I might try to remove the 'Capacity_type'
article from the publication.
I did this but then found the next article starting causing the exact same
errors as before.

E.g.
Step 2: exec sp_MSfetchidentityrange N'Area', 0

This leads me to believe it's not related specifically to any article.

Any help would be really appreciated as this is occuring on a production
server.
Chris Winstone
8/27/2005 5:46:03 AM
Hilary. Thanks for replying

There is MSrepl_identity_range on both the subscriber and publisher. There
is also a MSpub_identity_range table on the publisher. However I checked the
contents of all these tables and found that there was 82 records in
msrepl_identity_range on the publisher and only 3 records in
msrepl_identity_range on the subscriber. There are no records in
mspub_identity_range on the publisher.

Thanks

[quoted text, click to view]
Hilary Cotter
8/27/2005 6:34:00 AM
can you check for the existence of the following tables?

for merge -
distribution database on publisher - MSrepl_identity_range
publication and subscription database MSrepl_identity_range

for transactional -
distribution database on publisher - MSrepl_identity_range
publication database MSpub_identity_range

--
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
"Chris Winstone" <chris@offshore-shipbrokers.co.uk(donotspam)> wrote in
message news:CDAB657D-303A-4F64-AAD8-CCAEFE523D37@microsoft.com...
[quoted text, click to view]

Chris Winstone
9/2/2005 12:36:07 PM
Hillary. I ended up removing replication and setting up my publications
again. But alas I'm having problems creating a publication from a script.
See later post.

Thanks anyway.


"Chris Winstone" <chris@offshore-shipbrokers.co.uk(donotspam)> wrote in
message news:29CCA893-9E4B-4D9F-B18C-9210E8D910B5@microsoft.com...
[quoted text, click to view]

AddThis Social Bookmark Button