dbo.QER_PQERRiskIndexMakeProc
SQL_STORED_PROCEDURE
Created 2025-06-27T18:01:07.503 · modified 2026-04-14T23:20:40.297 · source: live DB sys.objects/sys.sql_expression_dependencies.
Parameters
| Name | Type | Output |
|---|---|---|
@uid_DialogColumn | varchar | no |
Referenced objects
| Schema | Object | Column/minor | Class |
|---|---|---|---|
| DialogColumn | OBJECT_OR_COLUMN | ||
| DialogTable | OBJECT_OR_COLUMN | ||
| QBM_PProcedureDrop | OBJECT_OR_COLUMN | ||
| QBM_PSessionErrorAdd | OBJECT_OR_COLUMN | ||
| QBM_PSQLCreate | OBJECT_OR_COLUMN | ||
| QER_PSQRiskIndexGetUpdate | OBJECT_OR_COLUMN | ||
| dbo | QBM_FGIColumnExistsInSchema | OBJECT_OR_COLUMN | |
| dbo | QBM_FSQProcedureDef | OBJECT_OR_COLUMN | |
| dbo | QER_FGIRiskIndexProcname | OBJECT_OR_COLUMN |
Source excerpt
First extracted SQL definition lines from the exported source. Use the full source page for complete context.
1 create procedure QER_PQERRiskIndexMakeProc (@uid_DialogColumn varchar(38)) as begin declare @SQLcmd nvarchar(max) declare @header nvarchar 2(max) declare @footer nvarchar(max) declare @Body nvarchar(max) declare @content1 nvarchar(max) declare @content2 nvarchar(max) declare @TableName nvarchar 3(32) declare @Columnname nvarchar(32) declare @UpdateString nvarchar(max) declare @Vardef nvarchar(max) = ' 4drop table if exists #DeltaQERRiskIndex 5 6create table #DeltaQERRiskIndex (XObjectKey varchar(138) collate database_default 7 , NewValue float default 0 8 ) 9 10' 11 declare @PostUpdate nvarchar(max) declare @procname varchar(128) declare @DebugSwitch int = 0 declare @DebugLevel char(1) = 'W' SET XACT_ABORT OFF BEGIN 12 TRY select @ProcName = dbo.QER_FGIRiskIndexProcname( @uid_dialogcolumn ) select top 1 @TableName = t.TableName , @Columnname = c.ColumnName from DialogColumn 13 c with (readpast) join DialogTable t with (readpast) on c.UID_DialogTable = t.UID_DialogTable where UID_DialogColumn = @uid_DialogColumn exec QER_PSQRiskIndexGetUpdate 14 @uid_DialogColumn, @UpdateString output select @PostUpdate = concat(' 15 select @ret = @@rowcount 16 17 if @ret > 0 18 begin 19 create index #DeltaQERRiskIndex1 on #DeltaQERRiskIndex (XObjectKey) include (NewValue) 20 21 update ' 22 , @TableName , ' 23 set ' , @Columnname , ' = y.NewValue ' , case when dbo.QBM_FGIColumnExistsInSchema(@TableName, 'XDateUpdated') = 1 and @Columnname 24 not like 'X[d,u][a,s][t,e][e,r]updated' then ', XDateUpdated = getutcdate(), XUserUpdated = ''QERRiskIndexCalculation'' ' else '' end ,' 25 from ' , 26@TableName , ' d join #DeltaQERRiskIndex y on d.XObjectKey = y.XObjectKey 27 ', '' , ' 28 truncate table #DeltaQERRiskIndex 29 30 end 31 ' ) select @SQLcmd 32 = dbo.QBM_FSQProcedureDef ( @ProcName , '' , concat(@Vardef , @updatestring , @PostUpdate) , concat('Procedure riskindex for Column : ' , @TableName , 33 '.' , @Columnname ) ) if @DebugSwitch > 0 begin print @SQLcmd end if @UpdateString > ' ' begin exec QBM_PSQLCreate @ProcName, 'P', @SQLcmd, @UnComment 34 = 0 end else begin exec QBM_PProcedureDrop @ProcName end END TRY BEGIN CATCH exec QBM_PSessionErrorAdd default RAISERROR ('', 18, 1) WITH NOWAIT END 35CATCH ende: return end 36
Module relation graph
Loading module relation graph…
Source-derived context
Generated from exported SQL module definitions plus read-only sandbox sys.objects/sys.parameters/sys.sql_expression_dependencies metadata. This is factual source evidence, not a semantic guess.
provenance: SQL definition export provenance: sandbox DB metadata modified: 2026-04-14T23:20:40.297
has TRY/CATCH error handling
Summary: calls QER_PSQRiskIndexGetUpdate, QBM_PSQLCreate, QBM_PProcedureDrop, QBM_PSessionErrorAdd; reads/joins DialogColumn, DialogTable
Declared parameters
| Parameter | Type | Direction |
|---|---|---|
@uid_DialogColumn | varchar(38) | input |
DML targets
None extracted.Read/join references
SQL dependency metadata
Config/session
Config: None extracted.
Session: None extracted.
DBQueue/tasks
None extracted.Temp tables / referenced variables
Temp: #DeltaQERRiskIndex #DeltaQERRiskIndex1
Variables: @uid_DialogColumn @SQLcmd @header @footer @Body @content1 @content2 @TableName @Columnname @UpdateString @Vardef @PostUpdate @procname @DebugSwitch @DebugLevel @ProcName @uid_dialogcolumn @ret @rowcount @updatestring @UnComment
Referenced by / reverse dependencies
Generated from live DB metadata, FK rows, and exported SQL dependency/source extraction. This is factual linkage evidence, not inferred behavior.
| Referencing object | Relation | Evidence |
|---|---|---|
| dbo.QER_ZRiskIndexMakeProc | SQL expression dependency | OBJECT_OR_COLUMN |
| dbo.QER_ZRiskIndexMakeProc | source text reference | has TRY/CATCH error handling |