Showing posts with label merge. Show all posts
Showing posts with label merge. Show all posts

Thursday, March 22, 2012

creating the subscription via RMO

Hi

I'm creating an anonymous merge HTTPS subscription using RMO and vb.net 2005.

I get the following error on the mergePullSubscription.create call

+ InnerException {"'@.job_login' must be a valid Windows Login in the form : 'MACHINE\Login' or 'DOMAIN\Login'. Please see the documentation for 'sp_addmergepullsubscription_agent'.
Changed database context to 'brucesTest'."} System.Exception
What do I need to do to get this parameter set ?

I'm using the code from BOL to create it...

Thanks
BruceHi, Bruce:

You can specify the agent's properties by do the following:

subscription.SynchronizationAgentProcessSecurity.Login = winLogin;
subscription.SynchronizationAgentProcessSecurity.Password = winPassword;

For a completed reference and code snippet, please refer to this TOP in BOL.

ms-help://MS.SQLCC.v9/MS.SQLSVR.v9.en/repref9/html/97a232ce-7171-4124-
8c30-4a4e7f991183.htm

Thanks
Yunwensql

Wednesday, March 7, 2012

Creating Peer-to-Peer Merge Replication

We have a situation exactly like that shown in the documentation for creating a peer-to-peer merge replication. That is, we have three servers, one each in Chicago, New York, and Bermuda. Users in each office will read and write to their respective servers and the servers will then replicate with one another. The documentation, however, only shows how to set up peer-to-peer for a transactional replication. The problem is that the various Manger Studio options and the database stored procedures are NOT the same between transactional and merge replication and on the face of it, merged replication does not support a peer-to-peer topology. Can somebody walk me through the process of creating a peer-to-peer merge replication, or else convince me that I should go with transaction with updating subscriptions -- in contravention of what the documentation seems to reccommend? I'd really appreciate it!

Thanks.

Randy

before any recommendations, what are your business requirements in terms of latency? regarding a merge replication, is there something else you require that prohibits you from doing a standard publication with two subscriptions?|||

In terms of business requirements the only issue is that three distinct set of users, in three different parts of the world, are updaing their own local servers but that update information needs to be reflected on all servers. The way my boss and I read the documentation, the two options are merge or transaction with updatable subscriptions. Between the two options, the documentation seems to encourage peer-to-peer merge replication.

As for latency, we're probably talking less than 50 transactions per second. Indeed, I suspect we are more in the 10 to 20 range. Since we have big pipes and good servers, I don't expect latency to be much of a problem no matter what we do.

Thanks for your input.

Randy

Friday, February 24, 2012

Creating Linked Server issues

I have a Merge Replication Setup. With 3 computers. One computer acts has a central publisher. The 2nd one is a subscriber, and republishes its data to the 3rd computer. Every thing is being done using Windows Authentication method. the 1st PC has SQL SERVER 2000 (Enterprise Manager, the works). The other two are SQL Server MSDE (Rel. A). My process is up and running and works, but heres my issue.

I need to script the replication installation process out., For future installations on machines that will be located in remote parts of the world. The will reside on a secure DSL network.

Anyone familiar with Scripting Merge Replication knows that once you've run certain scripts/procedures on your subscriber, you have to run a final procedure on the publisher to activate or initiate the subscriber as a valid one, and the you can start the Merge Agent on the subscriber, and voila! you're good. The procdure you run is called sp_addmergesubscription . It goes something like this :

BEGIN
exec sp_addmergesubscription @.publication = @.publicationname, @.subscriber = @.servername, @.subscriber_db = @.Attachedbname, @.subscription_type = N'pull', @.subscriber_type = N'global', @.subscription_priority = 56.250000, @.sync_type = N'automatic'
END

My intention was to embed this system in a stored proc on the publisher and then call it remotely from the subscriber, before starting the Agent. IT FAILS!!! This is my proc:

Create Procedure RunSp_AM_subscription(@.servername Varchar(30), @.IAdbname Varchar(20), @.Attachedbname Varchar(20))
AS

DECLARE @.publicationname Varchar(30)
SET @.publicationname = 'REPUBLISH-'+@.IAdbname+''

BEGIN
exec sp_addmergesubscription @.publication = @.publicationname, @.subscriber = @.servername, @.subscriber_db = @.Attachedbname, @.subscription_type = N'pull', @.subscriber_type = N'global', @.subscription_priority = 56.250000, @.sync_type = N'automatic'
END

When I call it locally ot works fine, but not otherwise......... :eek:

When I try to create a linked server SQL Server seems to think that one already exists (because Replication has already created the said server as a remote server). I think the fact that I am not using SQL Authentication might be a problem too.

Does anyone have any ideas? I mean seriously, any suggestions on what to do. This is qute Urgent...........

Thanks.

'Walealso how would I even call the proc assuming I'm able to create the linked server.

Tuesday, February 14, 2012

Creating custom merge profile

You can also in the Create Publication Wizard, select
Yes, minimize the amount of data on the Optimize
Synchronization page (@.keep_partition_changes = true),
and consider if column-level tracking is appropriate for
the business needs.
The timeout parameterss are usually adjusted only when
timeouts are an issue, and won't optimize your process.
You might want to look at this article to get more info
on Optimization:
http://www.microsoft.com/technet/pro.../sql/2000/main
tain/mergperf.mspx
HTH,
Paul Ibison SQL Server MVP, www.replicationanswers.com
(recommended sql server 2000 replication book:
http://www.nwsu.com/0974973602p.html)
Hi Paul,
thanks a lot.
Janez