Back to OIM Explorer

dbo.QER_PAssignmentCheckValid

Stored ProcedureSQL_STORED_PROCEDURESandbox DB

Stored Procedure.

Source: sandbox-db sys.sql_modules

Source size: 1.058 characters

Interpretation

  • Database routine. Review parameters, called procedures, DBQueue inserts, and QBM_PJobCreate helper calls before assuming side effects.

Relations

  • No extracted relations.

Typed Edges

  • references source dbo.QBM_FGIBitPatternXOrigin source text reference
  • references source dbo.QBM_FGISessionContext source text reference
  • references source dbo.QBM_FGISessionErrorRethrow source text reference
  • references source dbo.QBM_PSessionErrorAdd source text reference

Complete Source

SQL46 lines
1CREATE PROCEDURE QER_PAssignmentCheckValid(2  @UID_BaseTreeAssign varchar(38),3  @Parameters QBM_YparameterList READONLY,4  @GenProcID varchar(38)5)6AS7BEGIN8  DECLARE @QBM_BitPatternXOrigin_Direct int = dbo.QBM_FGIBitPatternXOrigin('|Direct|',9  0)10  SET XACT_ABORT OFF11  BEGIN TRY12    IF dbo.QBM_FGISessionContext('Transport') = ''13    BEGIN14      IF EXISTS(15        SELECT TOP 1 116        FROM @Parameters i17        JOIN BaseTree b18          ON i.Parameter1 = b.UID_Org19      LEFT20      OUTER21        JOIN OrgRootAssign r22          ON b.uid_orgroot = r.uid_orgroot AND r.UID_BaseTreeAssign = @UID_BaseTreeAssign23        WHERE24          isnull(r.IsAssignmentAllowed, 0) = 0 OR(isnull(r.IsDirectAssignmentAllowed, 0) = 0 AND convert(int,25      i.Parameter2) & @QBM_BitPatternXOrigin_Direct > 0))26      BEGIN27        SET XACT_ABORT28          ON29        RAISERROR('#LDS#Cannot make assignment because not permitted according to OrgRootAssign information.|',30        18,31        1)32          WITH nowait33      END34    END35  END TRY36  BEGIN CATCH37    EXEC QBM_PSessionErrorAdd DEFAULT38    DECLARE @Rethrow varchar(1000) = dbo.QBM_FGISessionErrorRethrow()39    RAISERROR(@Rethrow,40    18,41    1)42      WITH NOWAIT43  END CATCH44  ende:45  RETURN46END
Open raw exported source
SQL ยท Raw8 lines
1   create   procedure QER_PAssignmentCheckValid (@UID_BaseTreeAssign varchar(38)  , @Parameters QBM_YparameterList readonly , @GenProcID varchar2(38) ) as begin declare @QBM_BitPatternXOrigin_Direct int = dbo.QBM_FGIBitPatternXOrigin('|Direct|', 0)  SET XACT_ABORT OFF BEGIN TRY if dbo.QBM_FGISessionContext3 ('Transport') = '' begin  if exists ( select top 1 1 from @Parameters i join BaseTree b on i.Parameter1 = b.UID_Org left outer join OrgRootAssign r on4 b.uid_orgroot = r.uid_orgroot and r.UID_BaseTreeAssign = @UID_BaseTreeAssign where isnull(r.IsAssignmentAllowed, 0) = 0 or (isnull(r.IsDirectAssignmentAllowed5, 0) = 0 and convert(int, i.Parameter2) & @QBM_BitPatternXOrigin_Direct > 0 ) ) begin  set XACT_ABORT ON  raiserror( '#LDS#Cannot make assignment because not permitted according to OrgRootAssign information.|'6, 18, 1) with nowait end end    END TRY BEGIN CATCH exec QBM_PSessionErrorAdd default declare @Rethrow varchar(1000) = dbo.QBM_FGISessionErrorRethrow()7 RAISERROR (@Rethrow, 18, 1) WITH NOWAIT END CATCH ende: return end 8