Back to OIM Explorer

dbo.QBM_TIJob

Database TriggerSQL_TRIGGERSandbox DB

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

Source: sandbox-db sys.sql_modules

Source size: 796 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 4
  • References QBM_PDBQueueInsert_Bulk
  • Trigger parent table: Job

Typed Edges

  • queues DBQueue task QBM_ZPrePropJob at line 4 Bulk DBQueue insert -> QBM-K-CommonPrepropJob / QBM_ZPrePropJob at line 4
  • 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

SQL40 lines
1CREATE trigger QBM_TIJob2  ON Job FOR3INSERT 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    RETURN start:14    SELECT @GenProcID = dbo.QBM_FGISessionContext('')15    INSERT INTO @ConditionsToCheck(ContentFull)16    SELECT i.PreProcessorCondition17    FROM inserted i18    EXEC QBM_PPrePropCheckSyntax @ConditionsToCheck19    DECLARE @DBQueueElements_01 QBM_YDBQueueRaw20    INSERT INTO @DBQueueElements_01(object,21    subobject,22    genprocid)23    SELECT24      x.uid,25      NULL,26      @GenProcID27    FROM(28    SELECT uid_Job AS UID29    FROM inserted) AS x30    EXEC QBM_PDBQueueInsert_Bulk 'QBM-K-CommonPrepropJob',31      @DBQueueElements_0132  END TRY33  BEGIN CATCH34    EXEC QBM_PSessionErrorAdd DEFAULT35    RAISERROR('',36    18,37    1)38      WITH NOWAIT39  END CATCH40END
Open raw exported source
SQL ยท Raw6 lines
1 create   trigger QBM_TIJob on Job  for Insert 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 return start: select @GenProcID = dbo.QBM_FGISessionContext('')  insert into @ConditionsToCheck3 (ContentFull) select i.PreProcessorCondition from inserted i exec QBM_PPrePropCheckSyntax @ConditionsToCheck  declare @DBQueueElements_01 QBM_YDBQueueRaw4 insert into @DBQueueElements_01 (object, subobject, genprocid) select x.uid, null, @GenProcID from (select uid_Job as UID from inserted ) as x exec QBM_PDBQueueInsert_Bulk5 'QBM-K-CommonPrepropJob', @DBQueueElements_01 END TRY BEGIN CATCH exec QBM_PSessionErrorAdd default RAISERROR ('', 18, 1) WITH NOWAIT END CATCH end 6