My MSSQL trigger:
ALTER TRIGGER [dbo].[ioTrigger_dbo_vsolv_mst_tproddtchng]
ON [dbo].[vsolv_mst_tproddtchng]
for INSERT
AS
BEGIN
SET NOCOUNT ON;
INSERT OPENQUERY (LINKED,'SELECT proddtchng_product_gid,
proddtchng_mrp,
proddtchng_tndpwtax,
proddtchng_tndpwotax,
proddtchng_kldpwtax,
proddtchng_kldpwotax,
proddtchng_costprice,
proddtchng_website,
proddtchng_purpose,
proddtchng_weight,
proddtchng_suitable,
proddtchng_workingrange,
proddtchng_cutoff,
proddtchng_timedelay,
proddtchng_description,
proddtchng_validfrom,
proddtchng_validto,
proddtchng_createby,
proddtchng_createdate,
proddtchng_isactive,
proddtchng_isremoved
from vsolv_line_tn.vsolv_mst_tproddtchng')
SELECT
proddtchng_product_gid,
proddtchng_mrp,
proddtchng_tndpwtax,
proddtchng_tndpwotax,
proddtchng_kldpwtax,
proddtchng_kldpwotax,
proddtchng_costprice,
proddtchng_website,
proddtchng_purpose,
proddtchng_weight,
proddtchng_suitable,
proddtchng_workingrange,
proddtchng_cutoff,
proddtchng_timedelay,
proddtchng_description,
proddtchng_validfrom,
proddtchng_validto,
proddtchng_createby,
proddtchng_createdate,
proddtchng_isactive,
proddtchng_isremoved
FROM
inserted;
END
When I am executing the above trigger I am getting the following error:
OLE DB provider "MSDASQL" for linked server "LINKED" returned message "[MySQL][ODBC 5.3(a) Driver]Optional feature not supported". Msg 7391, Level 16, State 2, Procedure ioTrigger_dbo_vsolv_mst_tproddtchng, Line 8 The operation could not be performed because OLE DB provider "MSDASQL" for linked server "LINKED" was unable to begin a distributed transaction.
I have created a Linked server to Mysql from Sqlserver2008, I have already configured the DTC and its status is running, automatic, please help me how should I overcome the above error.
openquery
– Ven