AnsweredAssumed Answered

Error on Versioned Feature Class Triggers

Question asked by Mats_Hardy on Oct 9, 2018

I have create a versioned feature class CP_FACILITY on SQL Server 2014. The feature class only stores the geometry and few attributes while other text attributes are store in table FACILITY. Therefore, I use triggers to synchronize the attributes between CP_FACILITY and FACILITY.

 

I have created trigger on A table:

ALTER TRIGGER TR_CP_FACILITY_2_INS ON A562
AFTER INSERT
AS

.......

GO

 

also trigger on D table:

ALTER TRIGGER TR_CP_FACILITY_2_DEL ON D562
AFTER INSERT
AS

......

GO

 

The trigger TR_CP_FACILITY_2_INS runs fine but the trigger TR_CP_FACILITY_2_DEL has problem, whenever I delete a feature in CP_FACILITY, the following error is shwon:

 

Delete Feature: An unexpected failure occurred.Underlying DBMS error [HY000:[Microsoft][ODBC Driver 11 for SQL Server]Connection is busy with results for another command][CPIS.DBO.CP_FACILITY_2][STATE_ID = 1903]

 

Anyone know what I have done wrong?

Outcomes