Perform inserts from a trigger into a table on linked server - bad decision. This will great affects on insert performance in the source table ([dbo].[Table_1]) and also there is a distributed transaction, and configuring servers for support distributed transactions - nightmare.
One possible solution is:
On the source server you can create a synchronization queue table. For example:
CREATE TABLE dbo.SyncQueue ( QueueId INT IDENTITY(1,1), KeyForSync INT, -- Primary key value of record in dbo.SourceTable SyncStatus INT -- statuses can be: 0 - New, 1 - Synchronized, 2 - Error ) suppose you source table is CREATE TABLE dbo.SourceTable ( Key INT, -- primary key of the table Data varchar(xxx) )
Triger on dbo.SourceTable can quickly insert into dbo.SyncQueue record Key that you need synchronize
- Some periodically performed stored procedure can then insert records from the queue in table on the linked server.