dbo.ATT_PAttestationResetOneLevel
SQL_STORED_PROCEDURE
Created 2025-06-27T18:01:11.777 · modified 2026-04-14T23:20:42.817 · source: live DB sys.objects/sys.sql_expression_dependencies.
Parameters
| Name | Type | Output |
|---|---|---|
@uid_AttestationCase | varchar | no |
@NewLevel | int | no |
@GenProcID | varchar | no |
Referenced objects
| Schema | Object | Column/minor | Class |
|---|---|---|---|
| AttestationHelper | OBJECT_OR_COLUMN | ||
| QBM_PSessionErrorAdd | OBJECT_OR_COLUMN | ||
| dbo | QBM_FGISessionErrorRethrow | 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 ATT_PAttestationResetOneLevel (@uid_AttestationCase varchar(38) , @NewLevel int , @GenProcID varchar(38) ) as begin declare 2 @WhereclauseForMail nvarchar(1000) SET XACT_ABORT OFF BEGIN TRY if exists (select top 1 1 from AttestationHelper h where uid_AttestationCase = @uid_AttestationCase 3 and levelnumber = @NewLevel and ( h.decision > ' ' or h.UID_PersonInsteadOf > ' ' or h.uid_PersonAdditional > ' ' ) ) begin update Attestationhelper set 4 decision = '' , uid_PersonInsteadOf = null , uid_PersonAdditional = null from AttestationHelper h where uid_AttestationCase = @uid_AttestationCase and 5 levelnumber = @NewLevel and ( h.decision > ' ' or h.UID_PersonInsteadOf > ' ' or h.uid_PersonAdditional > ' ' ) end if exists (select top 1 1 from AttestationHelper 6 h where uid_AttestationCase = @uid_AttestationCase and levelnumber = @NewLevel and ( h.IsFromDelegation = 1 ) ) begin delete Attestationhelper where isFromDelegation 7 = 1 and uid_AttestationCase = @uid_AttestationCase and levelnumber = @NewLevel end END TRY BEGIN CATCH exec QBM_PSessionErrorAdd default declare @Rethrow 8 varchar(1000) = dbo.QBM_FGISessionErrorRethrow() RAISERROR (@Rethrow, 18, 1) WITH NOWAIT END CATCH ende: return end 9
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:42.817
has TRY/CATCH error handling
Summary: calls QBM_PSessionErrorAdd; writes UPDATE Attestationhelper, DELETE Attestationhelper; reads/joins AttestationHelper
Declared parameters
| Parameter | Type | Direction |
|---|---|---|
@uid_AttestationCase | varchar(38) | input |
@NewLevel | int | input |
@GenProcID | varchar(38) | input |
DML targets
UPDATE Attestationhelper DELETE AttestationhelperCalled routines
Read/join references
SQL dependency metadata
Config/session
Config: None extracted.
Session: None extracted.
DBQueue/tasks
None extracted.Temp tables / referenced variables
Temp: None extracted.
Variables: @uid_AttestationCase @NewLevel @GenProcID @WhereclauseForMail @Rethrow
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.ATT_TUAttestationCase | SQL expression dependency | OBJECT_OR_COLUMN |
| dbo.ATT_TUAttestationCase | source text reference | inserts DBQueue tasks, uses session context values, has TRY/CATCH error handling |