Questions tagged [transactional-replication]

Transactional replication typically starts with a snapshot of the publication database objects and data. As soon as the initial snapshot is taken, subsequent data changes and schema modifications made at the Publisher are usually delivered to the Subscriber as they occur (in near real time).

Transactional replication typically starts with a snapshot of the publication database objects and data.

As soon as the initial snapshot is taken, subsequent data changes and schema modifications made at the Publisher are usually delivered to the Subscriber as they occur (in near real time).

The data changes are applied to the Subscriber in the same order and within the same transaction boundaries as they occurred at the Publisher; therefore, within a publication, transactional consistency is guaranteed.

Transactional replication is typically used in server-to-server environments and is appropriate in each of the following cases:

  • You want incremental changes to be propagated to Subscribers as they occur. The application requires low latency between the time changes are made at the Publisher and the changes arrive at the Subscriber.

  • The application requires access to intermediate data states. For example, if a row changes five times, transactional replication allows an application to respond to each change (such as firing a trigger), not simply the net data change to the row.

  • The Publisher has a very high volume of insert, update, and delete activity. The Publisher or Subscriber is a non-SQL Server database, such as Oracle.

By default, Subscribers to transactional publications should be treated as read-only, because changes are not propagated back to the Publisher. However, transactional replication does offer options that allow updates at the Subscriber.

Source: Transactional Replication

290 questions
1
vote
0 answers

Can replicated commands be forced to follow each other in transactional replication?

We have transactional replication setup between an SQL Server 2012 box and a SQL Server 2016 box. Every half an hour the source table articles are altered by DELETE then INSERT sequence. This sequence comes from a stored procedure executed by an…
1
vote
1 answer

Connection error in Subscription between my SQL Server and Azure database

I'm having a lot of trouble with doing a replication between a SQL Server 2014 and Azure. I use a remote desktop to connect to the SQL Server machine and there, I start doing all the replication steps. I already made the SQL Server the distributor…
1
vote
0 answers

Datetime field not in sync in Transactional Replication - does default value matter?

I run 2012 SQL Server and I use the Transactional Replication to sync data to the replication server. I have no control over the application which uses the database. There is a table with the column ChangedWhen, DEFAULT VALUE GETDATE(). The App…
Petr
  • 11
  • 1
1
vote
1 answer

Replication SQL Server 2008 to Azure SQL DB login failure

I am trying to setup replication from SQL Server 2008 R2 (publisher and distributor) to Azure SQL database (subscriber). I configured the subscription on the SQL Server 2008 side (push) with a SQL Server User. In the replication job I see the…
1
vote
0 answers

SQL: Replicated transactions are waiting for the next Log back up or for mirroring partner to catch up

I have two SQL Server DB instances on the same machine with one hosting a replica of the other. In addition, I have transaction replication setup for all tables on the main instance to the replica. I have verified that the log reader and associated…
ReLeaf
  • 1,368
  • 1
  • 10
  • 17
1
vote
3 answers

How do I replicate a temporal table

I have a temporal table, and I want to replicate it using transactional replication. The history table cannot have a primary key required for transactional replication. When I try replicating the current table, replication fails because it cannot…
Steven Brown
  • 365
  • 3
  • 8
1
vote
0 answers

MSSQL Transactional Replication

I have an application that almost continuously works with inserting or updating data. Since multiple requests are handled asynchronous I wrote my queries like below. I used an example based on SO, but that's not what I'm actually doing. DECLARE…
1
vote
1 answer

SQL Transactional Replications with triggers running concurrently

I have setup SQL Server transactional replication to run continuously for two tables (Parent and child records). At the subscriber end, I have insert and update triggers on both replicated tables. These trigger all have the same code which queries…
MakkyNZ
  • 2,215
  • 5
  • 33
  • 53
1
vote
2 answers

How to avoid table locks and replicate large articles using transaction replication

We are planning to migrate our SQL on prem database to azure and this database has lot of tables and out of them few are very highly transaction table (contains millions of records), we want to minimize the down time of the application and decided…
1
vote
0 answers

Cannot add new subscription to remote SQL Server Publication

I have this setup: A publisher SQL Server Standard 2014 instance named GMSSERVER\SQLSTANDARD on Server A A subscriber SQL Server 2014 Express instance named CLAUDIOGMS\SQLEXPRESS2014 on Server B When I try to add a new subscription from…
1
vote
1 answer

Replication problem (distribution with subscriber) in SQL SERVER 2008 R2

We have transactional replication between two MS SQL Server 2008 R2. Our servers were rebooted because of failure of a hard drive. Replication automatically continued working. But in an hour after we received such error: The subscription(s)…
arena-ru
  • 990
  • 2
  • 12
  • 25
1
vote
0 answers

Synchronizing missing data on publisher and subscriber database tables (insert and update only missing data on destination) in sql server

In my case, we have some extra data rows in few tables on subscriber database, which I need to retain. I tried tablediff.exe utility which is traversing all the tables and creating Insert, update and delete queries in single SQL script, but I just…
1
vote
1 answer

Informix CDC API errors

I am getting errors while trying to run Informix CDC api. I copied the code https://www.ibm.com/support/knowledgecenter/SSGU8G_11.50.0/com.ibm.cdc.doc/ids_cdc_060.htm into cdcapi_INFORMIX.ec Ran as informix user login, I am getting error…
Sree
  • 337
  • 4
  • 10
1
vote
1 answer

Enabling generation of non-clustered indexes on subscription database for SQL Server 2012 transactional replication

We have a SQL script that we use to create a publication and its articles, along with a pull subscription. It's pretty basic, as we don't explicitly exclude any articles, rather take them all across to the subscriber (a database used for queries…
1
vote
1 answer

Replication Monitor: Cannot Connect to Publisher

Everything It was working fine for a quite long time period, but suddenly this evening I found that I the replication does not work and I cannot browse the publications in the Replication Monitor Please have a look at the attached image. The…
Kiko
  • 319
  • 1
  • 4
  • 16