Back to OIM Explorer

dbo.QBM_TUJob

Database TriggerSQL_TRIGGERSandbox DB

Database Trigger on Job. Bulk DBQueue insert -> QBM-K-CommonPrepropJob / QBM_ZPrePropJob at line 5; References QBM_PDBQueueInsert_Bulk; Trigger parent table: Job

Source: sandbox-db sys.sql_modules

Source size: 918 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-CommonPrepropJob / QBM_ZPrePropJob at line 5
  • References QBM_PDBQueueInsert_Bulk
  • Trigger parent table: Job

Typed Edges

  • queues DBQueue task QBM_ZPrePropJob at line 5 Bulk DBQueue insert -> QBM-K-CommonPrepropJob / QBM_ZPrePropJob at line 5
  • trigger on table Job Trigger parent table: Job
  • references source dbo.QBM_FGISessionContext source text reference
  • references source dbo.QBM_PDBQueueInsert_Bulk source text reference
  • references source dbo.QBM_PPrePropCheckSyntax source text reference
  • references source dbo.QBM_PSessionErrorAdd source text reference

Complete Source

SQL49 lines
1CREATE trigger QBM_TUJob2  ON Job FOR3UPDATE NOT FOR Replication4AS5BEGIN6  DECLARE @GenProcID varchar(38)7  DECLARE @ConditionsToCheck QBM_YParameterList8  BEGIN TRY9    IF EXISTS(10      SELECT TOP 1 111      FROM inserted)12    GOTO start13    IF EXISTS(14      SELECT TOP 1 115      FROM deleted)16    GOTO start17    RETURN start:18    SELECT @GenProcID = dbo.QBM_FGISessionContext('')19    IF20    UPDATE(PreProcessorCondition) OR21    UPDATE(UID_Jobchain)22    BEGIN23      INSERT INTO @ConditionsToCheck(ContentFull)24      SELECT i.PreProcessorCondition25      FROM inserted i26      EXEC QBM_PPrePropCheckSyntax @ConditionsToCheck27      DECLARE @DBQueueElements_01 QBM_YDBQueueRaw28      INSERT INTO @DBQueueElements_01(object,29      subobject,30      genprocid)31      SELECT32        x.uid,33        NULL,34        @GenProcID35      FROM(36      SELECT uid_Job AS UID37      FROM inserted) AS x38      EXEC QBM_PDBQueueInsert_Bulk 'QBM-K-CommonPrepropJob',39        @DBQueueElements_0140    END41  END TRY42  BEGIN CATCH43    EXEC QBM_PSessionErrorAdd DEFAULT44    RAISERROR('',45    18,46    1)47      WITH NOWAIT48  END CATCH49END
Open raw exported source
SQL ยท Raw7 lines
1  create   trigger QBM_TUJob on Job  for Update not for Replication as begin   declare @GenProcID varchar(38) declare @ConditionsToCheck QBM_YParameterList2 BEGIN TRY if exists (select top 1 1 from inserted) goto start if exists (select top 1 1 from deleted) goto start return start: select @GenProcID = dbo.QBM_FGISessionContext3('') if update(PreProcessorCondition) or update(UID_Jobchain) begin  insert into @ConditionsToCheck (ContentFull) select i.PreProcessorCondition from inserted4 i exec QBM_PPrePropCheckSyntax @ConditionsToCheck  declare @DBQueueElements_01 QBM_YDBQueueRaw insert into @DBQueueElements_01 (object, subobject, genprocid5) select x.uid, null, @GenProcID from (select uid_Job as UID from inserted ) as x exec QBM_PDBQueueInsert_Bulk 'QBM-K-CommonPrepropJob', @DBQueueElements_016 end END TRY BEGIN CATCH exec QBM_PSessionErrorAdd default RAISERROR ('', 18, 1) WITH NOWAIT END CATCH end 7