dbo.ADS_TDADSGroupInADSGroup

SQL_TRIGGER parent ADSGroupInADSGroup

Created 2025-06-27T18:01:23.510 · modified 2026-04-14T23:23:07.900 · source: live DB sys.objects/sys.sql_expression_dependencies.

Open formatted source/search result

Parameters

NameTypeOutput
No parameters.

Referenced objects

SchemaObjectColumn/minorClass
ADSGroupOBJECT_OR_COLUMN
ADSGroupcollectionOBJECT_OR_COLUMN
deletedOBJECT_OR_COLUMN
QBM_PDBQueueInsert_BulkOBJECT_OR_COLUMN
QBM_PSessionErrorAddOBJECT_OR_COLUMN
QBM_YDBQueueRawTYPE
dboQBM_FGIBitPatternXMarkedForDelOBJECT_OR_COLUMN
dboQBM_FGISessionContextOBJECT_OR_COLUMN

Source excerpt

First extracted SQL definition lines from the exported source. Use the full source page for complete context.

Open full formatted source

1create   trigger ADS_TDADSGroupInADSGroup on ADSGroupInADSGroup  for Delete not for Replication as begin  if exists (select top 1 1 from deleted
2) goto start return start: BEGIN TRY declare @QBM_BitPatternXMarkedForDel_OutStanding int = dbo.QBM_FGIBitPatternXMarkedForDel('|OutStanding|', 0)  declare
3 @GenProcID varchar(38) = dbo.QBM_FGISessionContext('')  if exists (select top 1 1 from deleted i join ADSGroup g on i.UID_ADSGroupParent = g.UID_ADSGroup
4 and 1 = g.HasReadOnlyMemberships and dbo.QBM_FGISessionContext ('Fullsync') = '' and i.XMarkedForDeletion & @QBM_BitPatternXMarkedForDel_OutStanding =
5 0 ) begin raiserror( '#LDS#Cannot delete {0} because assignment to groups with read only memberships are not permitted.|ADSGroupInADSGroup|', 18, 2) with
6 nowait end declare @DBQueueElements_01 QBM_YDBQueueRaw insert into @DBQueueElements_01 (object, subobject, genprocid) select x.uid, null, @GenProcID from
7 ( select uid_ADSGroupParent as uid from deleted union select UID_ADSGroupChild from deleted union  select co.uid_ADSGroupParent as uid from deleted i 
8join ADSGroupcollection co on i.UID_ADSGroupChild = co.UID_ADSGroupChild  union select co.uid_ADSGroupParent from deleted i join ADSGroupcollection co 
9on i.UID_ADSGroupParent = co.UID_ADSGroupChild  union select co.UID_ADSGroupChild from deleted i join ADSGroupcollection co on i.UID_ADSGroupChild = co.UID_ADSGroupParent
10  union select co.UID_ADSGroupChild from deleted i join ADSGroupcollection co on i.UID_ADSGroupParent = co.UID_ADSGroupParent ) as x exec QBM_PDBQueueInsert_Bulk
11 'ADS-K-ADSGroupInADSGroup', @DBQueueElements_01 END TRY BEGIN CATCH exec QBM_PSessionErrorAdd default RAISERROR ('', 18, 1) WITH NOWAIT END CATCH ende:
12 return end 
13

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:23:07.900

inserts DBQueue tasks uses session context values has TRY/CATCH error handling

Summary: calls QBM_PDBQueueInsert_Bulk, QBM_PSessionErrorAdd; writes INSERT into, DELETE not; reads/joins deleted, ADSGroup, ADSGroupcollection; uses session context Fullsync

Declared parameters

No declared parameters in sys.parameters for this object, or metadata was not available.

DML targets

INSERT into DELETE not

Config/session

Config: None extracted.

Session: Fullsync

DBQueue/tasks

ADS-K-ADSGroupInADSGroup

Temp tables / referenced variables

Temp: #LDS #Cannot

Variables: @QBM_BitPatternXMarkedForDel_OutStanding @GenProcID @DBQueueElements_01

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.

No reverse dependencies extracted.