Back to OIM Explorer

dbo.QBM_TDAssembly_Jobchain

Database TriggerSQL_TRIGGERSandbox DB

Database Trigger on JobChain. Bulk DBQueue insert -> QBM-K-ScriptAssemblyReset / QBM_ZScriptAssemblyReset at line 4; References QBM_PDBQueueInsert_Bulk; Trigger parent table: JobChain

Source: sandbox-db sys.sql_modules

Source size: 742 characters

Interpretation

  • Database trigger. Treat parent table and enqueue/object-layer calls as the main relation points.
  • DBQueue relation detected. Follow the task procedure and referenced-by list for async processing.

Relations

  • Bulk DBQueue insert -> QBM-K-ScriptAssemblyReset / QBM_ZScriptAssemblyReset at line 4
  • References QBM_PDBQueueInsert_Bulk
  • Trigger parent table: JobChain

Typed Edges

  • queues DBQueue task QBM_ZScriptAssemblyReset at line 4 Bulk DBQueue insert -> QBM-K-ScriptAssemblyReset / QBM_ZScriptAssemblyReset at line 4
  • trigger on table JobChain Trigger parent table: JobChain
  • references source dbo.QBM_FGISessionContext source text reference
  • references source dbo.QBM_FGITableName source text reference
  • references source dbo.QBM_PDBQueueInsert_Bulk source text reference
  • references source dbo.QBM_PSessionErrorAdd source text reference
  • references source dbo.QBM_TDAssembly_Job source text reference

Complete Source

SQL36 lines
1CREATE trigger QBM_TDAssembly_Jobchain2  ON Jobchain FOR3DELETE NOT FOR Replication4AS5BEGIN6  DECLARE @GenProcID varchar(38) = dbo.QBM_FGISessionContext('')7  BEGIN TRY8    IF EXISTS(9      SELECT TOP 1 110      FROM deleted)11    GOTO start12    RETURN start:13    DECLARE @DBQueueElements_01 QBM_YDBQueueRaw14    INSERT INTO @DBQueueElements_01(Object,15    SubObject,16    GenProcID)17    SELECT18      DISTINCT 'JobGen',19      dbo.QBM_FGITableName(i.UID_DialogTable),20      @GenProcID21    FROM deleted i22    JOIN JobEventGen e23      ON i.UID_JobChain = e.UID_JobChain24    WHERE25      i.IsDeactivatedByPreProcessor = 0 AND i.NoGenerate = 026    EXEC QBM_PDBQueueInsert_Bulk 'QBM-K-ScriptAssemblyReset',27      @DBQueueElements_0128  END TRY29  BEGIN CATCH30    EXEC QBM_PSessionErrorAdd DEFAULT31    RAISERROR('',32    18,33    1)34      WITH NOWAIT35  END CATCH36END
Open raw exported source
SQL ยท Raw6 lines
1   create   trigger QBM_TDAssembly_Jobchain on Jobchain  for Delete not for Replication as begin  declare @GenProcID varchar(38) = dbo.QBM_FGISessionContext2('') BEGIN TRY if exists (select top 1 1 from deleted) goto start return start: declare @DBQueueElements_01 QBM_YDBQueueRaw insert into @DBQueueElements_013(Object, SubObject, GenProcID) select distinct 'JobGen', dbo.QBM_FGITableName(i.UID_DialogTable) , @GenProcID from deleted i join JobEventGen e on i.UID_JobChain4 = e.UID_JobChain where i.IsDeactivatedByPreProcessor = 0 and i.NoGenerate = 0 exec QBM_PDBQueueInsert_Bulk 'QBM-K-ScriptAssemblyReset', @DBQueueElements_015  END TRY BEGIN CATCH exec QBM_PSessionErrorAdd default RAISERROR ('', 18, 1) WITH NOWAIT END CATCH end 6