Back to OIM Explorer

dbo.QBM_FGIDBSimulationAllowed

Scalar FunctionSQL_SCALAR_FUNCTIONSandbox DB

Scalar Function.

Source: sandbox-db sys.sql_modules

Source size: 523 characters

Interpretation

  • Database function. Usually supports views, validation, or calculated predicates; look at referenced-by entries for callers.

Relations

  • No extracted relations.

Typed Edges

  • references source dbo.QBM_FGISingleUserRunning source text reference

References

Referenced By

  • No direct source references extracted.

Complete Source

SQL32 lines
1CREATE FUNCTION dbo.QBM_FGIDBSimulationAllowed(2) RETURNS BIT3AS4BEGIN5  DECLARE @erg BIT = 16  IF EXISTS(7    SELECT TOP 1 18    FROM DialogDatabase d9    WITH(readpast)10  WHERE11    d.IsMainDatabase = 1 AND d.IsDBSchedulerDisabled = 1)12  BEGIN13    SELECT @erg = 014    GOTO endLabel15  END16  IF dbo.QBM_FGISingleUserRunning() = 117  BEGIN18    SELECT @erg = 019    GOTO endLabel20  END21  IF EXISTS(22    SELECT TOP 1 123    FROM DialogDatabase d24    WHERE25      d.IsMainDatabase = 1 AND UID_CutOffTask > ' ')26  BEGIN27    SELECT @erg = 028    GOTO endLabel29  END30  endLabel:31  RETURN(@erg)32END
Open raw exported source
SQL ยท Raw5 lines
1  create   function dbo.QBM_FGIDBSimulationAllowed() returns bit as begin declare @erg bit = 1 if exists (select top 1 1 from DialogDatabase d with2 (readpast) where d.IsMainDatabase = 1 and d.IsDBSchedulerDisabled = 1 ) begin select @erg = 0 goto endLabel end if dbo.QBM_FGISingleUserRunning () = 13 begin select @erg = 0 goto endLabel end  if exists (     select top 1 1 from DialogDatabase d where d.IsMainDatabase = 1 and UID_CutOffTask > ' ' ) begin4 select @erg = 0 goto endLabel end endLabel: return (@erg) end 5