Home   Package List   Routine Alphabetical List   Global Alphabetical List   FileMan Files List   FileMan Sub-Files List   Package Component Lists   Package-Namespace Mapping  
Routine: QAQAXREF

QAQAXREF.m

Go to the documentation of this file.
QAQAXREF ;HISC/DAD-EXECUTE SET AND KILL XREF'S ;5/12/92  14:08
 ;;1.7;QM Integration Module;;07/25/1995
 ; REQUIRED VARIABLES
 ;  QAQADICT = DATA DICTIONARY NUMBER
 ;  QAQAFLD  = FIELD NUMBER IN THE ABOVE DD
 ;  X        = FIELD VALUE TO BE CROSS REFERENCED
ENKILL ; *** Execute a field's cross reference kill logic
 D CHECK G:QAQAEXIT EXIT S QAQAXSAV=X
 F QAQAXREF=0:0 S QAQAXREF=$O(^DD(QAQADICT,QAQAFLD,1,QAQAXREF)) Q:QAQAXREF'>0  S X=QAQAXSAV X:$D(^DD(QAQADICT,QAQAFLD,1,QAQAXREF,2))#2 ^(2)
 G EXIT
ENSET ; *** Execute a field's cross reference set logic
 D CHECK G:QAQAEXIT EXIT S QAQAXSAV=X
 F QAQAXREF=0:0 S QAQAXREF=$O(^DD(QAQADICT,QAQAFLD,1,QAQAXREF)) Q:QAQAXREF'>0  S X=QAQAXSAV X:$D(^DD(QAQADICT,QAQAFLD,1,QAQAXREF,1))#2 ^(1)
EXIT ;
 K QAQADICT,QAQAEXIT,QAQAFLD,QAQAXREF,QAQAXSAV
 Q
CHECK ;
 S QAQAEXIT=$S($D(X)[0:1,$D(QAQADICT)[0:1,$D(QAQAFLD)[0:1,X="":1,QAQADICT'>0:1,QAQAFLD'>0:1,1:0)
 Q