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

sql server replication

group:

Publication XXX does not exist - Invalid Cursor State


Publication XXX does not exist - Invalid Cursor State Guy Thornton
2/5/2007 12:51:02 PM
sql server replication:
I have an application that uses merge replication to synchronize data between
an SQL 2000 server and MSDE 2000 clients that are desktop systems.

I have been testing this applicatio for some time while I developed and have
had no problems with replication.

This week, I have added additional users to my system and installed my
software to increase the app usage and get more testing.

All went well except for 1 user (Isn't this always the case). One user I've
added to my system, causes the following error:


Publication 'XXX' does not exist.
(Source: Merge Replication Provider (Agent); Error number: -2147201022)
---------------------------------------------------------------------------------------------------------------
Invalid cursor state
(Source: XXServer (Data source); Error number: 0)
---------------------------------------------------------------------------------------------------------------

I think the problem may be data related, but am unable to determine where
exactly the problem occurring ( I do not know how to turn on verbose logging)

When I got this error on the users' system, I tried replicating with their
user credentials on my system and get the same error.

Any ideas on what is causing this problem would greatly be appreciated.

Thanks,
Re: Publication XXX does not exist - Invalid Cursor State Paul Ibison
2/5/2007 9:57:38 PM
Guy - do you have SP4 on all involved nodes?
Cheers,
Paul Ibison SQL Server MVP, www.replicationanswers.com

Re: Publication XXX does not exist - Invalid Cursor State Guy Thornton
2/6/2007 4:54:02 AM
Hi Paul - None of my involved nodes are running SP4, they are all SP3a systems.

[quoted text, click to view]
Re: Publication XXX does not exist - Invalid Cursor State Guy Thornton
2/6/2007 5:25:01 AM
I understand Paul. I was wondering if you may have some suggestions on
things I could check. I will not be able to up my service pack as my
environment is regulated.

As I mentioned, all other users that we have now tested with works fine. It
is just one particular user that is having the problem. My publication is a
dynamically filtered publication based on user login. This to me would
explain how others work and the one does not. It also would seem logical
that the problem is data related. I just don't know how to dig deeper into
the publication to see why.

[quoted text, click to view]
Re: Publication XXX does not exist - Invalid Cursor State Guy Thornton
2/6/2007 7:30:01 AM
Thank you for the information, Paul. This did prove to be helpful to me.

I wanted to post back to let folks know that I was able to resolve this
problem just so others can have the information as reference.

I found that when I originally created this user account in our database,
they were setup, and were granted access to the merge publication through
Publication Properties, Publication Access Tab.

Afterwards we had to delete the user account from the database and re-create
it. I did not remove the user from the Publication access list before I
deleted and re-created the users' account. Somehow, the Publication access
list still reference the old user with the same name/pwd as the new user. To
correct, I removed the user from the publication access list, then deleted
and re-created the account and finally added the user back to the publication
access list.

Thank you again Paul for your points.

[quoted text, click to view]
Re: Publication XXX does not exist - Invalid Cursor State Paul Ibison
2/6/2007 1:11:44 PM
Guy,
at this stage I can only recommend upping the service pack level. I doubt
anyone will be able to try to repro your scenario as you are on a different
configuration, and that applies to a support call as well. If the same issue
applies to sp4, then let's continue the thread and I'll take another look.
Cheers,
Paul Ibison SQL Server MVP, www.replicationanswers.com



Re: Publication XXX does not exist - Invalid Cursor State Paul Ibison
2/6/2007 1:35:03 PM
Hi Guy,
there are some precedents of this issue (see
http://support.microsoft.com/kb/831997) that make me think it's likely to be
a MS replication procedure which is the culprit and is removed with a later
hotfix or sp4. To see if this is really the case you could run profiler
during syncing. Trap sp:starting, rpc:starting and exceptions (optionally
the related tsql as well). The error raised will tell you the spid and then
you can work backwards to see the last command issued.
Cheers,
Paul Ibison SQL Server MVP, www.replicationanswers.com

AddThis Social Bookmark Button