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

Thursday, March 22, 2012

Changing table relationships

We have a merge replication db that we have to drop a table index, add a
different index and change the relationships in one table. Will the laptops
pick up all of this or do I have to re-create the snapshot and also the
subscription? Thanks.
p.s. I assume I can't do this in EM?
David
for both SQL 2000 and SQL 2005 when you can't replicated these sorts of
schema changes.
I think you will have to drop the subscriptions and publications, make the
changes and try again.
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
"David C" <dlchase@.lifetimeinc.com> wrote in message
news:uv$gS77xHHA.4300@.TK2MSFTNGP04.phx.gbl...
> We have a merge replication db that we have to drop a table index, add a
> different index and change the relationships in one table. Will the
> laptops pick up all of this or do I have to re-create the snapshot and
> also the subscription? Thanks.
> p.s. I assume I can't do this in EM?
> David
>
sql

Thursday, March 8, 2012

Changing publisher for Merge Replication

We have a database application that is currently being replicated to 2
remote sites. In the near future, I expect that this will increase to many
more sites. My question is this, as we move forward it is probable that at
some time we will run into the need to replace the server that currently
functions as the publisher server. Is there some way to change all of the
publications to use a different server without having to remove replication
and reinstalling it?
TIA
Ron Lounsbury
Ron,
in my experience it is only possible to migrate replication databases from
one server to another if the server names are identical. If they are not,
then the best thing to do is to script out replication, change the
references to servernames and job owners appropriately, drop the 'old'
publications on the old server then recreate the publications on the new
server.
Another poster ran into this type of issue after restoring a merge published
database to another server and found when he tried to add a column he got
the error: 21260 "Schema replication failed because database '%s' on server
'%s' is not the original Publisher of table '%s'".
I investigated this and in sysmerge articles there is a publisherid. This
ID needs to have a corresponding record in sysmergepublications. However, in
sysmergepublications, the 'publisher' column needs to match the servername,
which it didn't in his case as he had restored to another servername. So the
problem is that the replication metadata tables 'hardcode' the original
server name.
HTH,
Paul Ibison
|||Paul
Thanks for the response. It's not what I wanted to hear, but I was
pretty much expecting it. One of the problems we will have is that not all
of our subscribers are connected at any given time, making it a bit
difficult to push the database out again. Also, there is a certain amount
of time (@.20 min or so) that the subscriber can't use the system while we
are doing this. Oh well, as I said, I was afraid that this would be the
answer.
Ron L
"Paul Ibison" <Paul.Ibison@.Pygmalion.Com> wrote in message
news:O6cJxkJeEHA.3476@.tk2msftngp13.phx.gbl...
> Ron,
> in my experience it is only possible to migrate replication databases from
> one server to another if the server names are identical. If they are not,
> then the best thing to do is to script out replication, change the
> references to servernames and job owners appropriately, drop the 'old'
> publications on the old server then recreate the publications on the new
> server.
> Another poster ran into this type of issue after restoring a merge
published
> database to another server and found when he tried to add a column he got
> the error: 21260 "Schema replication failed because database '%s' on
server
> '%s' is not the original Publisher of table '%s'".
> I investigated this and in sysmerge articles there is a publisherid. This
> ID needs to have a corresponding record in sysmergepublications. However,
in
> sysmergepublications, the 'publisher' column needs to match the
servername,
> which it didn't in his case as he had restored to another servername. So
the
> problem is that the replication metadata tables 'hardcode' the original
> server name.
> HTH,
> Paul Ibison
>

Friday, February 24, 2012

changing merge agent profile for HTTPS - mergeSubscriberType = anonymous

Hi


We are using HTTPS merge replication

Our setup is as follows:

subscription.CreateSyncAgentByDefault = False -- I wrote a windows service to synchronise
subscription.UseWebSynchronization = True
subscription.InternetSecurityMode = AuthenticationMethod.BasicAuthentication
subscription.SubscriberType = MergeSubscriberType.Anonymous

Some of our subscribers have low-quality internet connections - how do I get the agent at the publisher/distributer use a slower profile - I've read How to: Work with Replication Agent Profiles (Replication Transact-SQL Programming)
but can't see where you specifiy an alternate agent profile

On the distributer / publisher (same machine) I go to replication monitor -> Warnings and Agents - I can only set the profile for the snapshot agent....

thanks
Bruce

To see the various profiles, in replication monitor, right-click on a merge subscription and select Agent Profile. YOu should see various agent profiles, such as High Volume Server-to-Server Profile, Slow link agent profile, etc.

You can assign a non-default profile programmatically, look up AgentProfile Class.

|||

I right click on the merge subscription and there is no such option - is this 'cause subscription.CreateSyncAgentByDefault = False

Thanks
Bruce

|||
Bruce,

If your using RMO in your service to synchronise then try this property of the mergesynchronizationagent

mergesynchronizationagent.ProfileName = "Slow link agent profile."

Rab

Sunday, February 19, 2012

Changing IP

I am using merge replication with SQL ver 7, on a NT4 box. I need to
move one of seven subscribing servers to a new location which means
changing the IP address. I want to do the move without taking down
replication if possible. My plan is to move the box and change to new
IP address. Then update the WINS entry for the new address, and have
replication resume.
Should this work? Let me know if anyone can think of potential
problems.
thanks in advance, Jim
It should work. Replication is sensitive to subscriber name changes, not ip
address changes. Just make sure that you did not hard code an ip address in
the alias you may have created for this server in client network utility.
Hilary Cotter
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
"Jim" <ndpace@.att.net> wrote in message
news:c834d859.0409291039.4499a3df@.posting.google.c om...
> I am using merge replication with SQL ver 7, on a NT4 box. I need to
> move one of seven subscribing servers to a new location which means
> changing the IP address. I want to do the move without taking down
> replication if possible. My plan is to move the box and change to new
> IP address. Then update the WINS entry for the new address, and have
> replication resume.
> Should this work? Let me know if anyone can think of potential
> problems.
> thanks in advance, Jim
|||Guys!
I have the similar problem, but the server name will be changed also.
I believe it should be enough to call a kind of system SP, which will
replace old box names to the new ones. Could you point me to the right
direction?
Best regards,
Serge.
"Hilary Cotter" <hilary.cotter@.gmail.com> wrote in message
news:uEUCatlpEHA.1816@.TK2MSFTNGP09.phx.gbl...
> It should work. Replication is sensitive to subscriber name changes, not
ip
> address changes. Just make sure that you did not hard code an ip address
in
> the alias you may have created for this server in client network utility.
> --
> Hilary Cotter
> Looking for a SQL Server replication book?
> http://www.nwsu.com/0974973602.html
>
> "Jim" <ndpace@.att.net> wrote in message
> news:c834d859.0409291039.4499a3df@.posting.google.c om...
>
|||Serge,
Use Master
go
Sp_DropServer 'OldName'
GO
Use Master
go
Sp_Addserver 'NewName', 'local'
GO
Stop and Start SQL Services
This will rename your server, but you'll need to set up
the publications from fresh afterwards.
HTH,
Paul Ibison
(recommended sql server 2000 replication book:
http://www.nwsu.com/0974973602p.html)

Thursday, February 16, 2012

Changing field length for Merge

Hello -
I am using Merge replication, pushing subscriptions to clients, and SQL
Server 2000.
I need to change the field size in one of the tables that is in a
publication. Basically, from nvarchar[4] to nvarchar[8].
Can I do this without having to drop/add all subscribers?
I'm hoping that the schema changes can be propagated to clients with a
reinit-subscription.
Thanks.
Regards,
bruce
Please have a look at this article:
http://www.replicationanswers.com/AddColumn.asp. BTW, such changes are much
simpler (just Alter Table...) in SQL Server 2005.
HTH,
Paul Ibison SQL Server MVP, www.replicationanswers.com
(recommended sql server 2000 replication book:
http://www.nwsu.com/0974973602p.html)
|||Hi, I have the same problem than Bruce, I'm using a merge replication but
with a sligtly difference, the field I must change is part of the table's
primary key... I read the Paul Ibison's article but it look fine for fields
doesn't belongs to the primary key, because if I drop the field in order to
made the change on the field, it will throw an duplicate key error. So, what
else can I do?
Thanks in advance
"Paul Ibison" wrote:

> Please have a look at this article:
> http://www.replicationanswers.com/AddColumn.asp. BTW, such changes are much
> simpler (just Alter Table...) in SQL Server 2005.
> HTH,
> Paul Ibison SQL Server MVP, www.replicationanswers.com
> (recommended sql server 2000 replication book:
> http://www.nwsu.com/0974973602p.html)
>
>