Add article in merger replication

hello everyone,
is there any way to add article in already configured publication in merge replication with out snapshot of entire database.
as per my query it take snapshot of only newly added article not for entire db.
for example:
the distance between publisher and subscriber is 1200 km.
db size=50 gb(it's already configured in merge replication) after that as per our requirement I added one new article(size 1 gb) for that database, if I run snapshot agent it take whole db snapshot it's time consuming.
when I add one article in transaction replication it take snapshot of newly added article only. like that any way in merge replication.

No, this is not possible with Merge Replication.  You must generate a full snapshot, however, only the newly added article will be synchronized with existing subscribers.
Brandon Williams (blog |
linkedin)

Similar Messages

  • How to drop the tables (articles) in subscription database MERGE replication.

    We have configured the merge replication from publication server to subscription server,
    Here I mistakenly selecting few tables (articles) in publication,
    Now I need to remove those mistakenly selected tables in subscription server database . 
    Note: I am trying to below way but unable to remove those tables in subscription server.
    1<sup>st</sup> I unselected those tables (articles) in publication, but not working.
    Could please tell me the how to remove those tables in subscription database.

    Ok that is normal, dont worry, if you mistakenly  chosen few tables, just add the new tables
    that you forgot it, just make click on the publication, you only have to Re-run the snapshot agent, i mean you must generate another snapshot and then synchronice with your suscriber, and then you will not need DROP the tables on the suscriber, if you have
    troubles yet, please post imagens to help you more !
    Thanks and regards.

  • At what point is it a good practice to Drop and Add back an Article for Transactional Replication?

    Hi,
    We have transactional replication Setup in our company , a set of tables involved in replication needed to be reloaded on prod say about 12-13 Million rows .
    We decided to drop the articles and add it back to replication so that a new snapshot for the specific articles can be generated and the transfer of data is fast and no breakage in the replication.
    But what is the best practice or a threshold point for taking this route i.e dropping an article and adding it back ?
    I mean 
    when Is it good to go this route  i.e when the load is more than 10, 000 rows or 50.000 rows  100,000 or at what number do we start this process?
    Thanks,
    Jack

    That is a function of horsepower and bandwidth.
    If you do drop a table out rather than replicate a 1% change of its data, 100% of the table will need to be snapshotted which might cause havoc with users trying to access that table, and if you are running immediate sync all of the tables will need to be
    resnapshotted.
    With the Enterprise Edition of SQL Server you will be able to use a sync type of database_snapshot which will mean no locking, otherwise it could be painful. Initialize from a backup is also an option to save you the cost of a snapshot.
    looking for a book on SQL Server 2008 Administration?
    http://www.amazon.com/Microsoft-Server-2008-Management-Administration/dp/067233044X looking for a book on SQL Server 2008 Full-Text Search?
    http://www.amazon.com/Pro-Full-Text-Search-Server-2008/dp/1430215941

  • Merge Replication Error When Initialising subscription

    I have a SQL server 2005 server with a merge publication of 6 articles all of which are tables which is also the distributor. I have two existing subscriptions one from a SQL 2005
    Server and one from a SQL Server 2008 R2 Server both of which are working fine on this publication. I am trying to setup a third subscription to another SQL Server 2008 R2 server, the only difference with this server is that it is a named instance. I have
    forced the port to 1433, and created an alias on the publisher connectivity is not an issue or at least i don't think so.
    when I try to initialise the subscription from a new snapshot I get the below error;
    Error: 14151, Severity: 18, State: 1.
    Replication-Replication Merge Subsystem: agent failed. No subscription is on this publication or article.
    I've changed the agent profile and turned on verbose logging and output the results to a file the snapshot delivery is failing on the below for the first table;
    call sys.sp_MSsetup_identity_range (?,?,?,?,?,?,?,?)
    I've checked the subscriber and the table does indeed get dropped and created, permissions / routes don't seem to be an issue. I've included some of the verbose logging output below.
    2012-01-11 12:05:40.684 Microsoft SQL Server Merge Agent 9.00.3042.00
    2012-01-11 12:05:40.700 Copyright (c) 2005 Microsoft Corporation
    2012-01-11 12:05:40.716 Microsoft SQL Server Replication Agent: replmerg
    2012-01-11 12:05:40.716 
    2012-01-11 12:05:40.731 The timestamps prepended to the output lines are expressed in terms of UTC time.
    2012-01-11 12:05:40.747 User-specified agent parameter values:
    -Publisher PubServerName
    -PublisherDB UserDBName
    -Publication MtoC_M
    -Subscriber SubServerName
    -SubscriberDB UserDBName
    -Distributor PubServerName
    -DistributorSecurityMode 1
    -Continuous
    -OutputVerboseLevel 4
    -Output G:\CMcReplicationLogging\OUTPUT.TXT
    -XJOBID 0x5FFBC73C3A4A494A9E10C369696B1C72
    -XJOBNAME PubServerName-UserDBName-MtoC_M-SubServerName-29
    -XSTEPID 2
    -XSUBSYSTEM Merge
    -XSERVER PubServerName
    -XCMDLINE 0
    -XCancelEventHandle 000008EC
    -XParentProcessHandle 00000E9C
    2012-01-11 12:05:40.841 Percent Complete: 0
    2012-01-11 12:05:40.841 Connecting to Distributor 'PubServerName'
    2012-01-11 12:05:40.856 Repl Agent Status: 3
    2012-01-11 12:05:40.856 Connecting to OLE DB Distributor at datasource: 'PubServerName', location: '', catalog: '', providerstring: '' using provider 'SQLNCLI'
    2012-01-11 12:05:42.137 OLE DB Distributor: PubServerName
    DBMS: Microsoft SQL Server
    Version: 09.00.3042
    catalog name: 
    user name: dbo
    API conformance: 0
    SQL conformance: 0
    transaction capable: 1
    read only: F
    identifier quote char: "
    non_nullable_columns: 0
    owner usage: 15
    max table name len: 128
    max column name len: 128
    need long data len: 
    max columns in table: 1000
    max columns in index: 16
    max char literal len: 131072
    max statement len: 131072
    max row size: 131072
    2012-01-11 12:05:42.137 OLE DB Distributor 'PubServerName': {call sp_MSgetversion }
    2012-01-11 12:05:42.153 OLE DB Distributor 'PubServerName': {call sp_helpdistpublisher (N'PubServerName') }
    2012-01-11 12:05:42.169 OLE DB Distributor 'PubServerName': {call sp_MShelp_repl_agent (N'PubServerName', N'UserDBName', N'MtoC_M', N'SubServerName', N'UserDBName', 1)}
    2012-01-11 12:05:42.169 OLE DB Distributor 'PubServerName': select datasource, srvid from master..sysservers where upper(srvname) = upper(N'PubServerName')
    2012-01-11 12:05:42.184 OLE DB Distributor 'PubServerName': {call sp_MShelp_merge_agentid (0,N'UserDBName',N'MtoC_M',null,N'UserDBName',90,N'SubServerName')}
    2012-01-11 12:05:42.184 OLE DB Distributor 'PubServerName': {call sp_MShelp_profile (29, 4, N'')}
    2012-01-11 12:05:42.184 Percent Complete: 0
    2012-01-11 12:05:42.184 Connecting to OLE DB Publisher at datasource: 'PubServerName', location: '', catalog: 'UserDBName', providerstring: '' using provider 'SQLNCLI'
    2012-01-11 12:05:42.200 Initializing
    2012-01-11 12:05:42.200 Repl Agent Status: 1
    2012-01-11 12:05:42.216 OLE DB Distributor 'PubServerName': {call sys.sp_MSadd_merge_history90 (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:42.216 Percent Complete: 0
    2012-01-11 12:05:42.231 Connecting to Publisher 'PubServerName'
    2012-01-11 12:05:42.231 Repl Agent Status: 3
    2012-01-11 12:05:42.231 OLE DB Distributor 'PubServerName': {call sys.sp_MSadd_merge_history90 (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:43.153 OLE DB Publisher: PubServerName
    DBMS: Microsoft SQL Server
    Version: 09.00.3042
    catalog name: UserDBName
    user name: dbo
    API conformance: 0
    SQL conformance: 0
    transaction capable: 1
    read only: F
    identifier quote char: "
    non_nullable_columns: 0
    owner usage: 15
    max table name len: 128
    max column name len: 128
    need long data len: 
    max columns in table: 1000
    max columns in index: 16
    max char literal len: 131072
    max statement len: 131072
    max row size: 131072
    2012-01-11 12:05:43.169 OLE DB Publisher 'PubServerName': set nocount on declare @dbname sysname select @dbname = db_name() declare @collation nvarchar(255) select @collation = convert(nvarchar(255), databasepropertyex(@dbname, N'COLLATION')) select collationproperty(@collation,
    N'CODEPAGE') as 'CodePage', collationproperty(@collation, N'LCID') as 'LCID', collationproperty(@collation, N'COMPARISONSTYLE') as 'ComparisonStyle',cast(case when convert (int,databasepropertyex (@dbname,'comparisonstyle')) & 0x1 = 0x1 then 0 else 1 end
    as bit) as DB_CaseSensitive,cast(case when convert (int,serverproperty ('comparisonstyle')) & 0x1 = 0x1 then 0 else 1 end as bit) as Server_CaseSensitive set nocount off
    2012-01-11 12:05:43.169 OLE DB Publisher 'PubServerName': {call sp_MSgetversion }
    2012-01-11 12:05:43.200 Connecting to OLE DB Publisher at datasource: 'PubServerName', location: '', catalog: 'UserDBName', providerstring: '' using provider 'SQLNCLI'
    2012-01-11 12:05:44.137 OLE DB Publisher: PubServerName
    DBMS: Microsoft SQL Server
    Version: 09.00.3042
    catalog name: UserDBName
    user name: dbo
    API conformance: 0
    SQL conformance: 0
    transaction capable: 1
    read only: F
    identifier quote char: "
    non_nullable_columns: 0
    owner usage: 15
    max table name len: 128
    max column name len: 128
    need long data len: 
    max columns in table: 1000
    max columns in index: 16
    max char literal len: 131072
    max statement len: 131072
    max row size: 131072
    2012-01-11 12:05:44.137 OLE DB Publisher 'PubServerName': {call sp_MSchecksnapshotstatus (N'MtoC_M')}
    2012-01-11 12:05:44.153 OLE DB Publisher 'PubServerName': {call sp_helpmergepublication (N'MtoC_M')}
    2012-01-11 12:05:44.153 OLE DB Publisher 'PubServerName': {call sys.sp_MSgetreplicainfo(?,?,?,?,?,?,?,90)}
    2012-01-11 12:05:44.169 OLE DB Distributor 'PubServerName': {call sp_MShelp_repl_agent (N'PubServerName', N'UserDBName', N'MtoC_M', N'SubServerName', N'UserDBName', 1)}
    2012-01-11 12:05:44.169 Connecting to OLE DB Subscriber at datasource: 'SubServerName', location: '', catalog: 'UserDBName', providerstring: '' using provider 'SQLNCLI'
    2012-01-11 12:05:44.747 OLE DB Subscriber: SubServerName
    DBMS: Microsoft SQL Server
    Version: 10.50.1600
    catalog name: UserDBName
    user name: distributor_MtoC
    API conformance: 0
    SQL conformance: 0
    transaction capable: 1
    read only: F
    identifier quote char: "
    non_nullable_columns: 0
    owner usage: 15
    max table name len: 128
    max column name len: 128
    need long data len: 
    max columns in table: 1000
    max columns in index: 16
    max char literal len: 131072
    max statement len: 131072
    max row size: 131072
    2012-01-11 12:05:45.122 OLE DB Subscriber 'SubServerName': {call sp_MSgetversion }
    2012-01-11 12:05:45.216 OLE DB Subscriber 'SubServerName': {call sp_MSreplcheck_subscribe}
    2012-01-11 12:05:45.309 OLE DB Subscriber 'SubServerName': set nocount on declare @dbname sysname select @dbname = db_name() declare @collation nvarchar(255) select @collation = convert(nvarchar(255), databasepropertyex(@dbname, N'COLLATION')) select collationproperty(@collation,
    N'CODEPAGE') as 'CodePage', collationproperty(@collation, N'LCID') as 'LCID', collationproperty(@collation, N'COMPARISONSTYLE') as 'ComparisonStyle',cast(case when convert (int,databasepropertyex (@dbname,'comparisonstyle')) & 0x1 = 0x1 then 0 else 1 end
    as bit) as DB_CaseSensitive,cast(case when convert (int,serverproperty ('comparisonstyle')) & 0x1 = 0x1 then 0 else 1 end as bit) as Server_CaseSensitive set nocount off
    2012-01-11 12:05:45.419 Percent Complete: 0
    2012-01-11 12:05:45.419 OLE DB Subscriber 'SubServerName': {call sys.sp_MSadd_merge_history90 (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:45.419 Connecting to Subscriber 'SubServerName'
    2012-01-11 12:05:45.434 Repl Agent Status: 3
    2012-01-11 12:05:45.434 OLE DB Distributor 'PubServerName': {call sys.sp_MSadd_merge_history90 (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:45.559 Percent Complete: 0
    2012-01-11 12:05:45.559 OLE DB Subscriber 'SubServerName': {call sys.sp_MSadd_merge_history90 (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:45.559 Retrieving publication information
    2012-01-11 12:05:45.575 Repl Agent Status: 3
    2012-01-11 12:05:45.575 OLE DB Distributor 'PubServerName': {call sys.sp_MSadd_merge_history90 (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:45.653 OLE DB Subscriber 'SubServerName': {call sys.sp_MSmerge_upgrade_subscriber(1,?)}
    2012-01-11 12:05:45.653 Percent Complete: 0
    2012-01-11 12:05:45.669 Retrieving subscription information.
    2012-01-11 12:05:45.669 Repl Agent Status: 3
    2012-01-11 12:05:45.684 OLE DB Distributor 'PubServerName': {call sys.sp_MSadd_merge_history90 (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:45.763 OLE DB Publisher 'PubServerName': {call sys.sp_MSgetreplicainfo(?,?,?,?,?,?,?,90)}
    2012-01-11 12:05:45.763 OLE DB Publisher 'PubServerName': {call sys.sp_MShelpmergearticles (?,9000000,?) }
    2012-01-11 12:05:45.778 OLE DB Publisher 'PubServerName': {call sp_MSenumschemachange (?,?,9000000,?,0,1) }
    2012-01-11 12:05:45.794 OLE DB Subscriber 'SubServerName': {call sys.sp_MSadd_merge_history90 (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:45.888 OLE DB Publisher 'PubServerName': {call sys.sp_MSallocate_new_identity_range (?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:45.888 Percent Complete: 0
    2012-01-11 12:05:45.903 Applying the snapshot to the Subscriber
    2012-01-11 12:05:45.903 OLE DB Publisher 'PubServerName': {call sys.sp_MSallocate_new_identity_range (?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:45.903 Repl Agent Status: 3
    2012-01-11 12:05:45.919 OLE DB Publisher 'PubServerName': {call sys.sp_MSallocate_new_identity_range (?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:45.919 OLE DB Distributor 'PubServerName': {call sys.sp_MSadd_merge_history90 (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:45.919 OLE DB Publisher 'PubServerName': {call sys.sp_MSallocate_new_identity_range (?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:45.934 OLE DB Publisher 'PubServerName': {call sys.sp_MSallocate_new_identity_range (?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:45.950 OLE DB Publisher 'PubServerName': {call sys.sp_MSallocate_new_identity_range (?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:45.950 OLE DB Publisher 'PubServerName': {call sys.sp_MSallocate_new_identity_range (?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:45.966 OLE DB Publisher 'PubServerName': {call sys.sp_MSallocate_new_identity_range (?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:45.981 OLE DB Publisher 'PubServerName': {call sys.sp_MSallocate_new_identity_range (?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:45.997 OLE DB Publisher 'PubServerName': {call sys.sp_MSallocate_new_identity_range (?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:45.997 OLE DB Subscriber 'SubServerName': {call master..sp_helpreplicationoption ('merge')}
    2012-01-11 12:05:46.091 OLE DB Subscriber 'SubServerName': {call sys.sp_MSmergesubscribedb ('true', 0) }
    2012-01-11 12:05:47.263 OLE DB Subscriber 'SubServerName': {call sp_MSpublicationcleanup (?,?,?)}
    2012-01-11 12:05:47.372 OLE DB Subscriber 'SubServerName': {call sp_MSCleanupForPullReinit (?,?,?)}
    2012-01-11 12:05:47.481 OLE DB Subscriber 'SubServerName': {call sp_MSdropconstraints (N'tblEmailMessages',N'dbo')}
    2012-01-11 12:05:47.606 OLE DB Subscriber 'SubServerName': {call sp_MSdropconstraints (N'tblUser',N'dbo')}
    2012-01-11 12:05:47.716 OLE DB Subscriber 'SubServerName': {call sp_MSdropconstraints (N'tblDPVLocked',N'dbo')}
    2012-01-11 12:05:47.809 OLE DB Subscriber 'SubServerName': {call sp_MSdropconstraints (N'tblCaptureAppToken',N'dbo')}
    2012-01-11 12:05:47.903 OLE DB Subscriber 'SubServerName': {call sp_MSdropconstraints (N'tblCreditThresholdNotification',N'dbo')}
    2012-01-11 12:05:48.013 OLE DB Subscriber 'SubServerName': {call sp_MSdropconstraints (N'tblCreditPot',N'dbo')}
    2012-01-11 12:05:48.106 OLE DB Subscriber 'SubServerName': {call sys.sp_MSaddinitialpublication (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:48.247 OLE DB Subscriber 'SubServerName': {call sp_MSunmarkifneeded (N'tblEmailMessages',?, 1, ?, ?)}
    2012-01-11 12:05:48.403 OLE DB Subscriber 'SubServerName': {call sp_MSunmarkifneeded (N'tblUser',?, 1, ?, ?)}
    2012-01-11 12:05:48.513 OLE DB Subscriber 'SubServerName': {call sp_MSunmarkifneeded (N'tblDPVLocked',?, 1, ?, ?)}
    2012-01-11 12:05:48.606 OLE DB Subscriber 'SubServerName': {call sp_MSunmarkifneeded (N'tblCaptureAppToken',?, 1, ?, ?)}
    2012-01-11 12:05:48.700 OLE DB Subscriber 'SubServerName': {call sp_MSunmarkifneeded (N'tblCreditThresholdNotification',?, 1, ?, ?)}
    2012-01-11 12:05:48.809 OLE DB Subscriber 'SubServerName': {call sp_MSunmarkifneeded (N'tblCreditPot',?, 1, ?, ?)}
    2012-01-11 12:05:48.903 OLE DB Publisher 'PubServerName': {call sp_MShelpmergeschemaarticles(?)}
    2012-01-11 12:05:48.919 OLE DB Subscriber 'SubServerName': {call sp_MSaddinitialsubscription (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)}
    2012-01-11 12:05:49.059 OLE DB Distributor 'PubServerName': select datasource, srvid from master..sysservers where upper(srvname) = upper(N'PubServerName')
    2012-01-11 12:05:49.059 OLE DB Distributor 'PubServerName': {call sys.sp_MSadd_mergesubentry_indistdb (0,N'PubServerName',N'UserDBName',N'MtoC_M',N'SubServerName',N'UserDBName',0,1,0,N'',?,90)}
    2012-01-11 12:05:49.075 OLE DB Subscriber 'SubServerName': {call sp_MScreateglobalreplica (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,90)}
    2012-01-11 12:05:49.341 Connecting to OLE DB Subscriber at datasource: 'SubServerName', location: '', catalog: 'UserDBName', providerstring: '' using provider 'SQLNCLI'
    2012-01-11 12:05:49.825 OLE DB Subscriber: SubServerName
    DBMS: Microsoft SQL Server
    Version: 10.50.1600
    catalog name: UserDBName
    user name: distributor_MtoC
    API conformance: 0
    SQL conformance: 0
    transaction capable: 1
    read only: F
    identifier quote char: "
    non_nullable_columns: 0
    owner usage: 15
    max table name len: 128
    max column name len: 128
    need long data len: 
    max columns in table: 1000
    max columns in index: 16
    max char literal len: 131072
    max statement len: 131072
    max row size: 131072
    2012-01-11 12:05:50.185 OLE DB Subscriber: SubServerName
    DBMS: Microsoft SQL Server
    Version: 10.50.1600
    catalog name: UserDBName
    user name: distributor_MtoC
    API conformance: 0
    SQL conformance: 0
    transaction capable: 1
    read only: F
    identifier quote char: "
    non_nullable_columns: 0
    owner usage: 15
    max table name len: 128
    max column name len: 128
    need long data len: 
    max columns in table: 1000
    max columns in index: 16
    max char literal len: 131072
    max statement len: 131072
    max row size: 131072
    2012-01-11 12:05:50.325 OLE DB Subscriber 'SubServerName': {call sys.sp_MSregistermergesnappubid(?, ?)}
    2012-01-11 12:05:50.450 OLE DB Subscriber 'SubServerName': sp_MSacquiresnapshotdeliverysessionlock
    2012-01-11 12:05:50.544 OLE DB Subscriber 'SubServerName': sp_MStrypurgingoldsnapshotdeliveryprogress
    2012-01-11 12:05:50.810 OLE DB Subscriber 'SubServerName': {call sys.sp_MSadd_merge_history90 (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:50.966 [2%] OLE DB Subscriber 'SubServerName': {call sys.sp_MSadd_merge_history90 (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)}
    ꜻä㹒 ꜐äB 11 12:05ä谼砗꜐ä镴ĀPercent Complete: 4
    2012-01-11 12:05:50.997 Propagated 1 schema changes: 1 total
    2012-01-11 12:05:51.013 Repl Agent Status: 3
    2012-01-11 12:05:51.013 OLE DB Distributor 'PubServerName': {call sys.sp_MSadd_merge_history90 (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:51.091 [6%] OLE DB Subscriber 'SubServerName': {call sys.sp_MSadd_merge_history90 (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)}
    ꜻä㹒 ꜐äB 11 12:05ä谼砗꜐ä镴ĀPercent Complete: 6
    2012-01-11 12:05:51.122 Propagated 1 schema changes: 2 total
    2012-01-11 12:05:51.153 Repl Agent Status: 3
    2012-01-11 12:05:51.153 OLE DB Distributor 'PubServerName': {call sys.sp_MSadd_merge_history90 (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:51.200 OLE DB Subscriber 'SubServerName': {call sp_MSunmarkreplinfo (N'tblEmailMessages')}
    2012-01-11 12:05:51.200 [6%] Percent Complete: 6
    2012-01-11 12:05:51.231 Propagated 1 schema changes: 3 total
    2012-01-11 12:05:51.247 Repl Agent Status: 3
    2012-01-11 12:05:51.263 OLE DB Distributor 'PubServerName': {call sys.sp_MSadd_merge_history90 (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:51.325 OLE DB Subscriber 'SubServerName': sp_MSissnapshotitemapplied @snapshot_session_token = N'E:\Microsoft SQL Server\MSSQL.1\MSSQL\repldata\unc\PubServerName_UserDBName_MTOC_M\20120111115787\', @snapshot_progress_token = N'E:\Microsoft
    SQL Server\MSSQL.1\MSSQL\repldata\unc\PubServerName_UserDBName_MTOC_M\20120111115787\tblEmailMessages_2.sch'
    2012-01-11 12:05:51.435 drop Table [dbo].[tblEmailMessages]
    go
    SET ANSI_PADDING ON
    go
    SET ANSI_NULLS ON
    GO
    SET QUOTED_IDENTIFIER ON
    GO
    CREATE TABLE [dbo].[tblEmailMessages](
    [EmailMessageId] [bigint] IDENTITY(1,1) NOT FOR REPLICATION NOT NULL,
    [Guid] [nvarchar](32) NOT NULL,
    [Recipients] [varchar](8000) NOT NULL,
    [CcRecipients] [varchar](8000) NULL,
    [BccRecipients] [varchar](8000) NULL,
    [Sender] [varchar](8000) NOT NULL,
    [Subject] [nvarchar](4000) NOT NULL,
    [BodyText] [nvarchar](max) NULL,
    [BodyHTML] [nvarchar](max) NULL,
    [IsBodyEncrypted] [bit] NOT NULL CONSTRAINT [DF_tblEmailMessages_IsBodyEncrypted] DEFAULT ((0)),
    [Status] [tinyint] NOT NULL CONSTRAINT [DF_tblEmailMessages_Status] DEFAULT ((1)),
    [DateAdded] [datetime] NOT NULL CONSTRAINT [DR_tblEmailMessages_DateAdded] DEFAULT (getdate()),
    [rowguid] [uniqueidentifier] ROWGUIDCOL NOT NULL CONSTRAINT [MSmerge_df_rowguid_207F75F229994684BC3FAAE5BE4CD6EB] DEFAULT (newsequentialid())
    GO
    GRANT DELETE ON [dbo].[tblEmailMessages] TO [odintermediary]
    GO
    GRANT INSERT ON [dbo].[tblEmailMessages] TO [odintermediary]
    GO
    GRANT SELECT ON [dbo].[tblEmailMessages] TO [odintermediary]
    GO
    GRANT UPDATE ON [dbo].[tblEmailMessages] TO [odintermediary]
    GO
    SET ANSI_NULLS ON
    go
    SET QUOTED_IDENTIFIER ON
    go
    ALTER TABLE [dbo].[tblEmailMessages] ADD CONSTRAINT [PK_tblEmailMessage] PRIMARY KEY CLUSTERED 
    [EmailMessageId] ASC
    )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON)
    GO
    2012-01-11 12:05:51.450 OLE DB Subscriber 'SubServerName': drop Table [dbo].[tblEmailMessages]
    2012-01-11 12:05:51.560 OLE DB Subscriber 'SubServerName': SET ANSI_PADDING ON
    2012-01-11 12:05:51.669 OLE DB Subscriber 'SubServerName': SET ANSI_NULLS ON
    2012-01-11 12:05:51.778 OLE DB Subscriber 'SubServerName': SET QUOTED_IDENTIFIER ON
    2012-01-11 12:05:51.872 OLE DB Subscriber 'SubServerName': CREATE TABLE [dbo].[tblEmailMessages](
    [EmailMessageId] [bigint] IDENTITY(1,1) NOT FOR REPLICATION NOT NULL,
    [Guid] [nvarchar](32) NOT NULL,
    [Recipients] [varchar](8000) NOT NULL,
    [CcRecipients] [varchar](8000) NULL,
    [BccRecipients] [varchar](8000) NULL,
    [Sender] [varchar](8000) NOT NULL,
    [Subject] [nvarchar](4000) NOT NULL,
    [BodyText] [nvarchar](max) NULL,
    [BodyHTML] [nvarchar](max) NULL,
    [IsBodyEncrypted] [bit] NOT NULL CONSTRAINT [DF_tblEmailMessages_IsBodyEncrypted] DEFAULT ((0)),
    [Status] [tinyint] NOT NULL CONSTRAINT [DF_tblEmailMessages_Status] DEFAULT ((1)),
    [DateAdded] [datetime] NOT NULL CONSTRAINT [DR_tblEmailMessages_DateAdded] DEFAULT (getdate()),
    [rowguid] [uniqueidentifier] ROWGUIDCOL NOT NULL CONSTRAINT [MSmerge_df_rowguid_207F75F229994684BC3FAAE5BE4CD6EB] DEFAULT (newsequentialid())
    2012-01-11 12:05:51.981 OLE DB Subscriber 'SubServerName': GRANT DELETE ON [dbo].[tblEmailMessages] TO [odintermediary]
    2012-01-11 12:05:52.091 OLE DB Subscriber 'SubServerName': GRANT INSERT ON [dbo].[tblEmailMessages] TO [odintermediary]
    2012-01-11 12:05:52.200 OLE DB Subscriber 'SubServerName': GRANT SELECT ON [dbo].[tblEmailMessages] TO [odintermediary]
    2012-01-11 12:05:52.294 OLE DB Subscriber 'SubServerName': GRANT UPDATE ON [dbo].[tblEmailMessages] TO [odintermediary]
    2012-01-11 12:05:52.403 OLE DB Subscriber 'SubServerName': SET ANSI_NULLS ON
    2012-01-11 12:05:52.497 OLE DB Subscriber 'SubServerName': SET QUOTED_IDENTIFIER ON
    2012-01-11 12:05:52.606 OLE DB Subscriber 'SubServerName': ALTER TABLE [dbo].[tblEmailMessages] ADD CONSTRAINT [PK_tblEmailMessage] PRIMARY KEY CLUSTERED 
    [EmailMessageId] ASC
    )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON)
    2012-01-11 12:05:52.716 OLE DB Subscriber 'SubServerName': sp_MSrecordsnapshotdeliveryprogress @snapshot_session_token = N'E:\Microsoft SQL Server\MSSQL.1\MSSQL\repldata\unc\PubServerName_UserDBName_MTOC_M\20120111115787\', @snapshot_progress_token = N'E:\Microsoft
    SQL Server\MSSQL.1\MSSQL\repldata\unc\PubServerName_UserDBName_MTOC_M\20120111115787\tblEmailMessages_2.sch'
    2012-01-11 12:05:52.841 OLE DB Subscriber 'SubServerName': {call sys.sp_MSadd_merge_history90 (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:52.966 [6%] Percent Complete: 6
    2012-01-11 12:05:52.981 Applied script 'tblEmailMessages_2.sch'
    2012-01-11 12:05:52.981 Repl Agent Status: 3
    2012-01-11 12:05:52.981 OLE DB Distributor 'PubServerName': {call sys.sp_MSadd_merge_history90 (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:53.153 OLE DB Subscriber 'SubServerName': {call sys.sp_MSadd_merge_history90 (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:53.263 [6%] OLE DB Subscriber 'SubServerName': {call sys.sp_MSaddinitialarticle (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)}
    ꜻä㹒 ꜐äB 11 12:05ä谼砗꜐ä镴ĀPercent Complete: 6
    2012-01-11 12:05:53.294 Preparing table 'tblEmailMessages' for merge replication
    2012-01-11 12:05:53.294 Repl Agent Status: 3
    2012-01-11 12:05:53.310 OLE DB Distributor 'PubServerName': {call sys.sp_MSadd_merge_history90 (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:53.450 OLE DB Subscriber 'SubServerName': {call sp_MSupdatesysmergearticles (?,?,?,?,0)}
    2012-01-11 12:05:53.575 OLE DB Subscriber 'SubServerName': {call sys.sp_MSsetup_identity_range (?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:53.794 The merge process was unable to deliver the snapshot to the Subscriber. If using Web synchronization, the merge process may have been unable to create or write to the message file. When troubleshooting, restart the synchronization with
    verbose history logging and specify an output file to which to write.
    2012-01-11 12:05:53.825 OLE DB Subscriber 'SubServerName': {call sys.sp_MSadd_merge_history90 (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:53.966 Percent Complete: 6
    2012-01-11 12:05:53.966 No subscription is on this publication or article.
    2012-01-11 12:05:53.997 Repl Agent Status: 6
    2012-01-11 12:05:54.013 OLE DB Distributor 'PubServerName': {call sys.sp_MSadd_merge_history90 (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)}
    2012-01-11 12:05:54.216 Percent Complete: 0
    2012-01-11 12:05:54.231 Category:SQLSERVER
    Source: SubServerName
    Number: 14050
    Message: No subscription is on this publication or article.
    2012-01-11 12:05:54.247 Repl Agent Status: 3
    2012-01-11 12:05:54.372 Percent Complete: 0
    2012-01-11 12:05:54.372 Category:NULL
    Source: Merge Replication Provider
    Number: -2147201001
    Message: The merge process was unable to deliver the snapshot to the Subscriber. If using Web synchronization, the merge process may have been unable to create or write to the message file. When troubleshooting, restart the synchronization with verbose history
    logging and specify an output file to which to write.
    2012-01-11 12:05:54.388 Repl Agent Status: 3
    2012-01-11 12:05:54.388 Disconnecting from OLE DB Subscriber 'SubServerName'
    2012-01-11 12:05:54.388 Disconnecting from OLE DB Subscriber 'SubServerName'
    2012-01-11 12:05:54.403 Disconnecting from OLE DB Subscriber 'SubServerName'
    2012-01-11 12:05:54.403 Disconnecting from OLE DB Subscriber 'SubServerName'
    2012-01-11 12:05:54.403 Disconnecting from OLE DB Publisher 'PubServerName'
    2012-01-11 12:05:54.419 Disconnecting from OLE DB Publisher 'PubServerName'
    2012-01-11 12:05:54.419 Disconnecting from OLE DB Publisher 'PubServerName'
    2012-01-11 12:05:54.419 Disconnecting from OLE DB Publisher 'PubServerName'
    2012-01-11 12:05:54.435 Disconnecting from OLE DB Distributor 'PubServerName'
    2012-01-11 12:05:54.435 Disconnecting from OLE DB Distributor 'PubServerName'
    2012-01-11 12:05:54.450 The merge process will restart after waiting 30 second(s)...
    Percent Complete: 0
    Any help would be much appreciated.
    Thanks
    Chris 

    The error happens on this table every time.
    The schema of the table is below;
    CREATE TABLE [dbo].[tblEmailMessages](
    [EmailMessageId] [bigint] IDENTITY(1,1) NOT FOR REPLICATION NOT NULL,
    [Guid] [nvarchar](32) NOT NULL,
    [Recipients] [varchar](8000) NOT NULL,
    [CcRecipients] [varchar](8000) NULL,
    [BccRecipients] [varchar](8000) NULL,
    [Sender] [varchar](8000) NOT NULL,
    [Subject] [nvarchar](4000) NOT NULL,
    [BodyText] [nvarchar](max) NULL,
    [BodyHTML] [nvarchar](max) NULL,
    [IsBodyEncrypted] [bit] NOT NULL CONSTRAINT [DF_tblEmailMessages_IsBodyEncrypted] DEFAULT ((0)),
    [Status] [tinyint] NOT NULL CONSTRAINT [DF_tblEmailMessages_Status] DEFAULT ((1)),
    [DateAdded] [datetime] NOT NULL CONSTRAINT [DR_tblEmailMessages_DateAdded] DEFAULT (getdate()),
    [rowguid] [uniqueidentifier] ROWGUIDCOL NOT NULL CONSTRAINT [MSmerge_df_rowguid_207F75F229994684BC3FAAE5BE4CD6EB] DEFAULT
    (newsequentialid())
    The table gets dropped and recreated each time i try to reinitialise the subscription.  I can't remove the article at the moment as two other servers subscribe to the publication.
    Thanks for your help
    Chris
    I am the master of my fate: I am the captain of my soul.

  • Update query is slow with merge replication

    Hello friend,
    I have a database with enabling merge replication.
    Then the problem is update query is taking more time.
    But when I disable the merge triggers then it'll update quickly.
    I really appreciate your
    quick response.
    Thanks.

    Hi Manjula,
    According to your description, the update query is slow after configuring merge replication. There are some proposals for you troubleshooting this issue as follows.
    1. Perform regular index maintenance, update statistics, re-index, on the following Replication system tables.
        •MSmerge_contents
        •MSmerge_genhistory
        •MSmerge_tombstone
        •MSmerge_current_partition_mappings
        •MSmerge_past_partition_mappings
    2. Make sure that your tables involved in the query have suitable indexes. Also do the re-indexing and update the statistics for these tables. Additionally, you can use
    Database Engine Tuning Advisor to tune databases for better query performance.
    Here are some related articles for your reference.
    http://blogs.msdn.com/b/chrissk/archive/2010/02/01/sql-server-merge-replication-best-practices.aspx
    http://technet.microsoft.com/en-us/library/ms177500(v=sql.105).aspx
    Thanks,
    Lydia Zhang

  • Snapshot Error When Adding Article to Transactional Replication

    I am trying to add an table articles to my transactional replication setup.   When I do, the snapshot error fails with the following message:
    Source: Microsoft.SqlServer.Smo
    Target Site: Microsoft.SqlServer.Management.Smo.SqlSmoObject GetSmoObject(Microsoft.SqlServer.Management.Sdk.Sfc.Urn)
    Message: Attempt to retrieve data for object failed for Server '<servername>'.
    Stack:    at Microsoft.SqlServer.Management.Smo.Server.GetSmoObject(Urn urn)
       at Microsoft.SqlServer.Replication.Snapshot.SmoScriptingManager.BuildSmoObjectArrayAndUrnLookupTable(IDictionary& dictUrnKeyArticleScriptingBundles)
       at Microsoft.SqlServer.Replication.Snapshot.SmoScriptingManager.DoScripting()
       at Microsoft.SqlServer.Replication.Snapshot.SqlServerSnapshotProvider.DoScripting()
       at Microsoft.SqlServer.Replication.Snapshot.SqlServerSnapshotProvider.GenerateSnapshot()
       at Microsoft.SqlServer.Replication.SnapshotGenerationAgent.InternalRun()
       at Microsoft.SqlServer.Replication.AgentCore.Run() (Source: Microsoft.SqlServer.Smo, Error number: 0)
    Get help: http://help/0
    Source: Microsoft.SqlServer.Smo
    Target Site: Microsoft.SqlServer.Management.Smo.ObjectKeyBase CreateKeyFromUrn(Microsoft.SqlServer.Management.Sdk.Sfc.Urn)
    Message: The input Urn must specify Name at level UserDefinedFunction.
    Stack:    at Microsoft.SqlServer.Management.Smo.SchemaCollectionBase.CreateKeyFromUrn(Urn urn)
       at Microsoft.SqlServer.Management.Smo.Server.GetSmoObjectRec(Urn urn)
       at Microsoft.SqlServer.Management.Smo.Server.GetSmoObject(Urn urn) (Source: Microsoft.SqlServer.Smo, Error number: 0)
    Get help: http://help/0
    Specifics:
    Transactional replication:  Both Immediate Sync and Allow Anonymous are set to 0.
    Publisher and Distributer are same server:  SQL Server Standard 2008 R2 (10.50.4000.0) on Windows 2008 R2 SP1
    If I add even one table article (doesn't matter, I've tried different ones), I get the error above when I run the snapshot agent.
    If I remove the table just added and rerun the snapshot agent, it succeeds with the message "A snapshot was not generated because no subscriptions needed initialization", so at least I don't have to reinitialize (thank goodness!).
    Any ideas as to what might be causing this, and how I can add articles to my existing publication?
    Thanks in advance for your help.

    Hi John V.Barone,
    I’m writing to follow up with you on this post. Was the problem resolved after performing our action plan steps? If not, according to your error message, we need to verify if it is caused by replicating Meta Data corruption. You can check if there is a bad
    row
    in “sysarticles” (for a table) or “sysschemaarticles” (for a UDF) for which we do not have a corresponding “ObjectId” in sysobjects . If yes, delete
    manually  this row
    from Published (sysarticles, sysschemaarticles, syssubscriptions) and Distribution DB (MSsubscriptions,sysschemaarticles,MSarticles).
    Regards,
    Sofiya Li
    Sofiya Li
    TechNet Community Support

  • DataBase relation tables loses in suscribers in Merge Replication

    Hi all
    I noticed that after cheking the database relation in the suscribers after installing the merge replication.
    the relations in tables that I have in my Publisher database do not appear in the suscribers database.
    Is this normal ? Do I have to define again the tables relations in the suscribers ?
    Thanks in advance
    James

    Hi James,
    Please check your article properties and verify you have Copy foreign key constraints set to
    True.
    Brandon Williams (blog |
    linkedin)

  • Identity Management in a Pull Merge Replication at Subscriber

    I am facing SQL Server Replication issue (Identity Management in a Pull Merge Replication at Subscriber).
    Replication situation:
    Distributor and the Publisher are in one server running Windows Server 2012 Std and SQL Server 2012 Std
    One Subscriber PC running Windows 7 Professional and SQL Server 2012 Express Edition
    Both are connected through the internet using VPN
    The Problem:
    Subscriber has an article (Table) [DocumentItems] where its Identity field [DocumentItemsID] is managed by Replication and was assigned the following range:
    ([DocumentItemsID]>(280649) AND [DocumentItemsID]<=(290649) OR [DocumentItemsID]>(290649) AND DocumentItemsID]<=(300649)
    The server was disconnected from electricity several times. Every time the Subscriber PC is up, The [DocumentItemsID] field will pick an identity out of its range like 330035 when inserting new rows.
    The issue happened 3 times. I fixed the problem by a manual reseed:
        DBCC CHECKIDENT('DocumentItems' , RESEED, xxxx)
    Where xxxx is the MAX existing value for [DocumentItemsID] + 1
    Once the electricity is disconnected again, the same problem occurs.
    Does anybody have any idea what is happening? And why the [DocumentItemsID] field was assigned values out of its range?
    Thanks

    I am confused as to where/when this problem is happening.
    From what you describe the publisher is disconnected from the subscriber by the power failure. During this time is your subscriber accepting data?
    The subscriber will not increment it's range until it does a synchronization. Perhaps what is happening is that you have a power failure, and the subscriber is still running. It accepts inserts and eventually an insert is more than the assigned range. In
    this case all inserts will fail until the subscriber syncs and after that the range in incremented. If these inserts are done in a batch, lets say 100,000 rows then entire batch will fail as it exceeds the possible identity values and then you will find that
    your identity range is incremented even though the inserts failed.
    What I would do is use manual identity range management and set your subscriber range manually to somehting high, or to have a -ve increment and a seed of 0.
    looking for a book on SQL Server 2008 Administration?
    http://www.amazon.com/Microsoft-Server-2008-Management-Administration/dp/067233044X looking for a book on SQL Server 2008 Full-Text Search?
    http://www.amazon.com/Pro-Full-Text-Search-Server-2008/dp/1430215941

  • SQL PULL Merge Replication over web - totally unreliable?

    Hi,
    We have problems performing SQL PULL merge replication over the web.  Most of the time it works fine, but periodically we experience issues as described below.  Our application uses SQL Express for subscribers and we have our own C# RMO code for
    the agent.  We have eliminated our application as the source of the problem by setting up a full SQL Server as a subscriber and using the built in agent.  It experiences the same problems.
    1. Unable to download a snapshot.
    After reinitializing a subscriber, the snapshot will partially download and will then suddenly stop with the error:
        The connection with the server was terminated abnormally
    There is no obvious timeout issue, the error typically occurs as soon as one of the .bcp files is about to be downloaded.  It's often the same .bcp file that has the problem, but not always so there is no consistency.
    The only solution is to continually retry until the download eventually succeeds.  Recreating the snapshot before retrying seems to improve the chances of a successful sync.
    2. Unable to perform a normal sync (i.e. an update, rather than a full snapshot)
    An attempt to perform a sync results in the following information being logged:
        The upload message to be sent to Publisher 'SERVER2' is being generated
        The merge process is using Exchange ID 'F82F1A56-A81A-4786-A469-7A76259F9ED8' for this web synchronization session.
        No data needed to be merged.
        Request message generated, now making it ready for upload.
        Upload request size is 1895 bytes.
    At this point the sync simply stops doing anything.  There are no errors, the agent still appears to be running, but nothing else happens.
    We typically experience this problem once every few weeks.  Reinitializing a subscriber does not help, the same problem occurs.  The only solution is to recreate the snapshot and then to reinitialize the subscriber.  This then requires the
    subscriber to perform a full sync which takes around 45 minutes for our dataset.
    I am aware through online searches that others have experienced similar issues with SQL replication over web.  Are there any practical solutions to these issues, or is SQL replication over web simply broken?

    Hi Brandon, I noticed a post from you back towards the end of last year where you said you were giving up on it.  Did you ever get it resolved?  If not, did you identify a viable alternative solution?
    We need to replicate a SQL database to mobile tablets over 3G.  We've invested a lot of time and effort trying to make this solution work and to find that even using straight SQL server to SQL server has the same issues is disconcerting.
    One possible option is that although we currently use merge replication, that was really just a bad design decision taken early on.  We only perform one way replication, all our articles are flagged as one way only, server down to clients.  I have
    considered maybe moving towards transactional replication but unless I'm 100% certain I won't hit the same kind of issues, it really isn't viable to invest the time and effort.

  • Renaming publication articles in transactional replication

    Hello,
    I am using SQL 2012 SE and implementing transactional replication. I need to insert the rows from publisher database tables to new tables, drop the old tables and rename the new tables with the old table names. 
    For example:
    Publisher database tables that are being replicated: 
    Table1
    Table2
    Table3
    and I am going to create new tables in publisher database
    Table1_new
    Table2_new
    Table3_new
    Move data from 
    Table1--->Table1_new
    Table2--->Table2_new
    Table3--->Table3_new
    Drop constraints from and then tables (does this require articles to be removed from replication?)
    Table1
    Table2
    Table3
    Rename 
    Table1_new to Table1
    Table2_new to Table2
    Table3_new to Table3
    Does this require replication to set up from scratch or add the three articles only to replication? Is there a way this can be done without pausing or reinitializing replication or without removing articles and adding them back?
    Thanks. 

    Set  immediate_sync to false.
    Then drop the articles from the subscription and the publication. Add the new ones back in. Add them to the subcribers and then run the snapshot. The snapshot will only be for the newly added tables.
    looking for a book on SQL Server 2008 Administration?
    http://www.amazon.com/Microsoft-Server-2008-Management-Administration/dp/067233044X looking for a book on SQL Server 2008 Full-Text Search?
    http://www.amazon.com/Pro-Full-Text-Search-Server-2008/dp/1430215941
    I want to do this as part of a sql server agent job. Is it possible to do with TSQL?
    EXEC sp_dropsubscription 'NewPublication','Table1','Subscriber','Subscriber_db'
    EXEC sp_dropsubscription 'NewPublication','Table2','Subscriber','Subscriber_db'
    EXEC sp_dropsubscription 'NewPublication','Table3','Subscriber','Subscriber_db'EXEC sp_droparticle @publication = 'NewPublication', @article = 'Table1', @force_invalidate_snapshot = 1;
    EXEC sp_droparticle @publication = 'NewPublication', @article = 'Table2', @force_invalidate_snapshot = 1;
    EXEC sp_droparticle @publication = 'NewPublication', @article = 'Table3', @force_invalidate_snapshot = 1;
    go
    use [WesbiteDB]
    exec sp_rename 'Table1','Table1_Old'
    exec sp_rename 'Table2','Table2_Old'
    exec sp_rename 'Table3','Table3_Old'
    exec sp_rename 'Table1_new','Table1'
    exec sp_rename 'Table2_new','Table2'
    exec sp_rename 'Table3_new','Table3'
    go
    use [WesbiteDB]
    EXEC sp_addarticle @publication = 'NewPublication', @article = 'Table1', @source_object = N'Table1', @type = N'logbased', @pre_creation_cmd = N'drop', @destination_table = N'Table1';
    EXEC sp_addarticle @publication = 'NewPublication', @article = 'Table2', @source_object = N'Table2', @type = N'logbased', @pre_creation_cmd = N'drop', @destination_table = N'Table2';
    EXEC sp_addarticle @publication = 'NewPublication', @article = 'Table3', @source_object = N'Table3', @type = N'logbased', @pre_creation_cmd = N'drop', @destination_table = N'Table3';
    EXEC sp_refreshsubscriptions @publication = N'NewPublication';
    Does that look right?

  • Merge Replication: subscriber database error

    Hello
    We have a principal application database running on SQL Server 2005, which has 300 GB information.
    This database is synchronized with multiple subscribers using merge replication agent, allowing changes at both the publisher and subscribers.
    Client applications connect to the subscribers and not the publisher, so the information is loaded in the subscribers.
    Last week, one of the subscribers had storage level error (broken discs) that caused corruption in the file system of the server.
    Then, the merge replication with this server began to fail due to bad sectors of the file system. But the database remained online, and the application continued to function normally, so new information was loaded in database.
    Because disk errors, it was not possible backed up the affected database or copy databases files to save the information. Subscribers regular backups were NOT performed.
    After resolving disk errors and repaired the file system, database was restored,
    but had consistency errors which were repaired by the DBCC CHECKDB command with
    repair_allow_data_loss option.
    Comparing the number of records before and after repair, we estimates that some records were lost in the database.
    Replication has not been restored yet.
    Now we have the following questions:
    - What happens with lost data in the subscriber database if the merge synchronization is reactivated? We estimate that the lost data will be replicated to the Publisher, and want to avoid that.
    - Is there any way to sync (download) data from the Publisher to the Subscriber to load the missing records again? Avoiding of course the upload from the subscriber to the publisher.
    - If the above point is possible, may you then make the upload to the publisher to sync the information loaded into the database subscriber?
    - If these actions are not possible, have we another ways to sync the information, to avoid losing data in the subscriber?
    Thanks in advance
    Javier
    Javier Mariani

    Hi,
    You can configure the Synchronization direction in Article Property. Right-click the Publication, click Properties. In the Articles page, set the properties of the articles. See the image:
    Here is a thread for your reference:
    http://social.msdn.microsoft.com/Forums/sqlserver/en-US/dc21b614-b736-409b-883e-3af6c75ab546/merge-replication-synchronization-direction-as-downloadonly-to-subscriber-allow-subscriber?forum=sqlreplication
    Thanks.
    Tracy Cai
    TechNet Community Support

  • Slow merge replication over a WAN link - only downloads

    Hi all,
    We've been using SQL Server merge replication for a few years to synchronise data between our data centres, but we are now suffering with a big performance issue. This may be because the amount of data we are synchronising has increased a lot this year.
    Our publisher is an always-on data centre in the UK. Our subscriber is a mobile data centre that travels around the world and is on for periods of up to a week at a time, approx. 25 times a year. However, it also spends the same amount of time (if not more)
    switched off whilst on its travels - it is a well travelled data centre!
    We have 5 database that we synchronise on these servers. However, one of our databases has high numbers of data changes between periods of subscriber downtime and our issue is that it take days to catch up when the server is powered up - the other databases
    are fine.
    Downloads from publisher to subscriber run at about 1.5 rows a second (which is annoying when we have hundreds of thousands of rows) but strangely uploads from subscriber to publisher run about ten times faster.
    Things I have checked / tried:
    all tables have non-clustered primary keys on guid columns that have the rowguid property set
    changing the generation levelling threshold doesn't help
    setting the agent profile to high volume doesn't help
    running a trace at the publisher and subscriber shows the queries are all running very fast (less than 20 m/s generally, but there are gaps of 200 m/s or so between some batches of queries)
    analysis on our WAN link shows we have huge amounts of bandwidth spare
    analysis on our servers show we have huge amounts of Ram and CPU spare
    Some of the places the subscriber is at do suffer from high latency but this doesn't seem to have an impact - 300 m/s or 100m/s and we still get the same poor performance.
    One things I did wonder about - does the replication confirm to the publisher every time it has successfully processed a row at the subscriber? If we have thousands of rows and there is a latency on the line will this compound the issue if it confirms each
    item? If this does happen, is there a way to batch up messages between publisher and subscriber?
    Any help that you can offer will be gladly received!
    Thanks
    Mark

    1) merge replication processes the uploads/downloads in batches. So no, there is no confirmation for each row processes, but there is per batch. If there is an error/conflict a batch is retried as singletons (a single row processed at a time), so you need
    to minimize conflicts/errors.
    2) No, but you should use pull and wan accelerators for max performance and change your profile to use 2000 for the following:
    MaxDownloadChanges 
    MaxUploadChanges
    UploadGenerationsPerBatch  
    DownloadGenerationsPerBatch 
    UploadReadChangesPerBatch 
    DownloadReadChangesPerBatch 
    UploadWriteChangesPerBatch 
    DownloadWriteChangesPerBatch 
    set network packet size to a large value - you will need to work with your wan engineer to find out what works best. 32k will likely be best.
    Also you may want to copy a file of a known size from your publisher to your subscriber and then from your subscriber to your publisher to see if there is a significant difference in time. For drives will yield significant differences.
    I have found that you may have a trigger which is generating a large volume of unnessary changes. You will need to see what table/article is generating all the changes and evaluate whether the changes are legit.
    Precomputed partitions should speed up the enumeration times. Ensure you have supporting indexes - the missing indexes DMV helps here.
    Lastly you may find that a reinitialization is faster than processing the changes.
    looking for a book on SQL Server 2008 Administration?
    http://www.amazon.com/Microsoft-Server-2008-Management-Administration/dp/067233044X looking for a book on SQL Server 2008 Full-Text Search?
    http://www.amazon.com/Pro-Full-Text-Search-Server-2008/dp/1430215941

  • Violation of Primary Key in Merge Replication

    I have one Publisher and one Subscriber. They have
    a UK
    (Col1, Col2), PK is col1 + col2, and
    the MERGE
    REPLICATION adds a ROWGUID. Sometimes
    they insert the same row when they are offline ( they generate the same UK, it's not IDENTITY column), because
    of it, they generate different ROWGUID for the same row. Then, when I run the JOB for Merge Replication, I have a PRIMARY
    KEY violation. I need to use the UK instead of ROWGUID.
    It is possible?
    Example:
    Table_1 (Publisher)
    Name: John (UK)
    ID: 1234 (UK)
    ROWGUID: xxxxx (Created by Merge Replication)
    Table_1 (Subscriber)
    Name: John (UK)
    ID: 1234 (UK)
    ROWGUID: yyyyy (Created by Merge Replication)

    Hi Alex R,
    From your description, you want to use the UK(col1, col2) instead of ROWGUID, right? If so, it is not possible.
    To use your own column as rowguid column in merge replication, your column should have the following properties:
    • Should be of Uniqueidentifier datatype
    • Should have the ROWGUIDCOL property set
    • Should not allow NULLs
    • Should have a default of newid()
    Also please note that only one column can have the ROWGUIDCOL attribute in a table, in other words, we can only specify one column to be
    rowguid column in merge replication.
    Reference:
    https://msdn.microsoft.com/en-us/library/ms152746.aspx?f=255&MSPPError=-2147217396
    Thanks,
    Lydia Zhang
    Lydia Zhang
    TechNet Community Support

  • Merge replication - multi site, multi distributor, publisher, subscribers ...

    Hi,
    We have 2 sites at the moment. Each site has 2 servers. To reduce network load I was aiming at doing the following with a merge replication :
    * configure one server at each site to be distributor and publisher
    * configure the other server at each site to be a subscriber
    * configure the 2 publishers to also be subscribers to each other to sync the sites.
    Or even better:
    * have all the servers be distributors, publishers and subscribers, so that if one dies, who cares as they all have the same configuration.
    Also, I was thinking of:
    * having the distributor and publishers use a DFS share replicated on both sites (or maybe the same share on each sql server ? not sure what the best practice is on this one)
    However, I can't seem to find a good post / thread where it describes this kind of scenario in a step by step way nor what happens to the identity range management.
    If you could share any light on this or point me to the right English terms to describe the above scenario, thanks in advance.
    Olivier
    PS: We only have STD edition, so peer to peer and AG are not available to US. (which is why we are using merge)
    PS2: One way I could see this work is if I manually set the identity columns in the tables so that they won't overlap and make the range management manual. Then just setup publications / distributors and subscribers on each node. (But if I can dodge the
    manual management, it be great)

    Hi Brandon,
    Thx for the reply
    we are using web synchronization.
    According to the documentation ('The business logic handler you specify is executed for every row that is synchronized.') I would think this will do exactly the same as our trigger on the article.
    When we would use a business logic handler to update the record which is just uploaded to the Publisher I think we will end up with the same checksum error.
    We worked around the problem by not changing the status of orders once they are uploaded to the Publisher.
    For that part of the process we now have only 2 statusses anymore :
    - Not to be sent to central server
    - Upload(ed) to central server. 
    So an order is created at the subscriber and has the status 'not to be sent to central server'
    In a synchro-window the user can mark orders which must be uploaded to the central server.
    Only when the users clicks on the synchro button the orders which are marked (on screen) to be synchronised will get the status 'Upload(ed) to central server' and the pull subscriptions is started.
    On the central server we process only the articles with the status 'Upload(ed) to central server'.
    Before we had the statusses :
    - Not to be sent to central server
    - Upload to central server. 
    - Uploaded to central server.
    And we had our own trigger on the Publisher which updated the status of records from 'Upload to central server ' to 'uploaded to central server' which was not reliable because we often had checksum errors on that article.

  • MERGE REPLICATION - HIGH VOLUME OF CHANGES

    Hi everybody, i wanna ask you if somebody can tell me some recomendations when you have setted a merge replication environment and you have to replicate millions of records to some suscribers.

    Hi carlosadrr,
    According to your description, you have setted a merge replication environment and have to replicate millions of records to some subscribers.
    Based on my research, one key parameter to consider when performing batch updates against tables enabled for Merge Replication is 'generation_leveling_threshold'.  This setting controls how many data changes should be grouped into one generations (or batch).
    So to improve the Merge synchronization performance:
    1) Increase the BATCH size of the generation.  For 10 million changes, try with setting at 10,000.
    EXEC sp_changemergepublication
    @publication='<publication name>',
    @property= 'generation_leveling_threshold',
    @value= '10000'
    2) Execute sp_MSmakegeneration to call the generation leveling process.
    For more information about how to Reducing Impact of Large Updates on Merge Replication, please refer to the following article:
    http://blogs.msdn.com/b/repltalk/archive/2011/04/24/reducing-impact-of-large-updates-on-merge-replication.aspx
    If you have any question, please feel free to let me know.
    Regards,
    Jerry Li

Maybe you are looking for

  • Is there a way to bring the schema names forward when you deploy a mapping?

    Hi all, I am working in a database instance where there are objects in multiple schemas needed for a single mapping. Currently I have to create a grant statement and then create a synonym to get the deployed package to compile and run. Is there an op

  • Creating a photo gallery with upload feature.

    I am making a photo gallery for my website. I think it would be cool to allow the upload of images to the server. I will make the gallery search for images in the folder on the server and display them, but that is not my problem. My problem is how to

  • Current time in module pool programming in text field

    Hello Friends, In module pool programming ther is a input output field for time i want the current system time should be displayed in that field and when user press saves tht time should get saved in the database tables. regards, Sunny

  • Apache httpd 2.x.x 2.2.12 vulnerabilities

    I had some problems with FMS 3.5.3 apache 2.2.9, after upgrade to apache 2.2.15 the system became stable. I detect with snort a lot of apache exploit attempts. Does anyone had problems with Apache 2.2.9? Best Regards, Sérgio Henrique

  • How to add text to a drag and drop object

    Hi everyone, I am quite a beginner with Flash so do excuse me. First, I am not sure if what I want to achieve may actually be impossible with Flash. I presently use MX 2004, but will shortly be upgrading to CS3. But if you know the answer for MX 2004