[613] | 1 | GMRGUT2 ;CISC/RM-DATA DICTIONARY UTILITIES (cont.) ;5/28/92
|
---|
| 2 | ;;3.0;Text Generator;;Jan 24, 1996
|
---|
| 3 | EN1 ; ENTRY FROM THE SET LOGIC OF THE ATD XREF ON CLASSIFICATION FIELD
|
---|
| 4 | ; (#.04) OF THE AGGREGATE TERM (#124.2) FILE
|
---|
| 5 | S GMRG(0)=$S($D(^GMRD(124.2,DA,0)):^(0),1:""),GMRG(0)=$S(GMRG=.03:X_"^"_$P(GMRG(0),"^",4),GMRG=.04:$P(GMRG(0),"^",3)_"^"_X,1:$P(GMRG(0),"^",3,4)),GMRG=$S($D(^GMRD(124.25,+$P(GMRG(0),"^",2),0)):$P(^(0),U,3),1:"") G:'GMRG A1
|
---|
| 6 | I $P(GMRG(0),"^")'="",$P(GMRG(0),"^",2)'="" S ^GMRD(124.2,"ATD",$P(GMRG(0),"^"),$P(GMRG(0),"^",2),DA)=""
|
---|
| 7 | A1 F GMRG=7:1:10 I $D(^GMRD(124.25,+X,GMRG)) D DL12,ST12
|
---|
| 8 | K GMRG,GMRGPRM
|
---|
| 9 | Q
|
---|
| 10 | DL12 ;
|
---|
| 11 | S GMRG("X")=X,X=$S($D(^GMRD(124.2,DA,GMRG)):^(GMRG),1:"") F GMRG(0)=0:0 S GMRG(0)=$O(^DD(124.2,GMRG,1,GMRG(0))) Q:GMRG(0)'>0 X:$D(^DD(124.2,GMRG,1,GMRG(0),2)) ^(2)
|
---|
| 12 | S X=GMRG("X"),^GMRD(124.2,DA,GMRG)=""
|
---|
| 13 | Q
|
---|
| 14 | ST12 ;
|
---|
| 15 | S GMRG("X")=X,X=$S($D(^GMRD(124.25,+X,GMRG)):^(GMRG),1:""),^GMRD(124.2,DA,GMRG)=X I X'="" F GMRG(0)=0:0 S GMRG(0)=$O(^DD(124.2,GMRG,1,GMRG(0))) Q:GMRG(0)'>0 X:$D(^DD(124.2,GMRG,1,GMRG(0),1)) ^(1)
|
---|
| 16 | S X=GMRG("X")
|
---|
| 17 | Q
|
---|
| 18 | EN2 ; ENTRY FROM KILL LOGIC ON ATD XREF OF CLASSIFICATION FIELD (#.04)
|
---|
| 19 | ; OF THE AGGREGATE TERM (#124.2) FILE
|
---|
| 20 | S GMRG(0)=$S($D(^GMRD(124.2,DA,0)):^(0),1:""),GMRG(0)=$S(GMRG=.03:X_"^"_$P(GMRG(0),"^",4),GMRG=.04:$P(GMRG(0),"^",3)_"^"_X,1:$P(GMRG(0),"^",3,4)),GMRG=$S($D(^GMRD(124.25,+$P(GMRG(0),"^",2),0)):$P(^(0),U,3),1:"") G A2:'GMRG&'$D(GMRGX("DEL"))
|
---|
| 21 | I $P(GMRG(0),"^")'="",$P(GMRG(0),"^",2)'="" K ^GMRD(124.2,"ATD",$P(GMRG(0),"^"),$P(GMRG(0),"^",2),DA)
|
---|
| 22 | A2 F GMRG=7:1:10 I $D(^GMRD(124.25,+X,GMRG)) D DL12
|
---|
| 23 | K GMRG,GMRGPRM
|
---|
| 24 | Q
|
---|
| 25 | EN3 ; ENTRY FROM SET LOGIC ON ATD XREF OF BEGIN TEXT (#2) FIELD OF THE
|
---|
| 26 | ; GMR TERM CLASSIFICATION (#124.25) FILE
|
---|
| 27 | S GMRGX("X")=X,GMRGX("DA")=DA,X=DA F DA=0:0 S DA=$O(^GMRD(124.2,"CL",X,DA)) Q:DA'>0 W "." S GMRG=.04 D EN1
|
---|
| 28 | S X=GMRGX("X"),DA=GMRGX("DA")
|
---|
| 29 | K GMRGX
|
---|
| 30 | Q
|
---|
| 31 | EN4 ; ENTRY FROM KILL LOGIC ON ATD XREF OF BEGIN TEXT (#2) FIELD OF THE
|
---|
| 32 | ; GMR TERM CLASSIFICATION (#124.25) FILE.
|
---|
| 33 | S GMRGX("X")=X,GMRGX("DA")=DA,X=DA,GMRGX("DEL")=1 F DA=0:0 S DA=$O(^GMRD(124.2,"CL",X,DA)) Q:DA'>0 W "." S GMRG=.04 D EN2
|
---|
| 34 | S X=GMRGX("X"),DA=GMRGX("DA") K GMRGX
|
---|
| 35 | Q
|
---|
| 36 | EN5 ;ENTRY TO SET & KILL XREF FROM ACHTXT^MUMPS XREF ON .01 SUB
|
---|
| 37 | ;SUB FIELD OF CHILDREN (#1 FIELD) OF THE 124.2 FILE
|
---|
| 38 | Q:$D(GMRGXVER) S GMRG=$S($D(^GMRD(124.2,X,0)):^(0),1:""),GMRG("X")=X
|
---|
| 39 | F GMRG(2)=1:1:3,5 S X=$P(GMRG,"^",GMRG(2)),GMRG(3)=$S(GMRG(2)'=5:GMRG(2),1:4) D PRC5
|
---|
| 40 | S X=GMRG("X")
|
---|
| 41 | K GMRG
|
---|
| 42 | Q
|
---|
| 43 | PRC5 ;
|
---|
| 44 | I GMRG(0)=0,X'="" D DEL5^GMRGUT3
|
---|
| 45 | I GMRG(0)=1,X'="" D SET5^GMRGUT3
|
---|
| 46 | Q
|
---|
| 47 | EN6 ;ENTRY FROM ATXTUP XREF ON THE TERM FIELD (#.01) , ATYUP XREF OF
|
---|
| 48 | ; THE TYPE OF TERM (.02) FIELD, THE APKUP XREF OF THE PACKAGE (.03)
|
---|
| 49 | ; FIELD, AND THE ANDUP OF THE NODE IDENTIFICATION (.05) FIELD OF THE
|
---|
| 50 | ; GMR AGGREGATE TERM (#124.2) FILE.
|
---|
| 51 | Q:$D(GMRGXVER) S GMRGX("ODA1")=$S($D(DA(1)):DA(1),1:"@"),GMRGX("ODA")=DA
|
---|
| 52 | F DA(1)=0:0 S DA(1)=$O(^GMRD(124.2,"AKID",GMRGX("ODA"),DA(1))) Q:DA(1)'>0 F GMRGX(1)=0,1 F DA=0:0 S DA=$O(^GMRD(124.2,"AKID",GMRGX("ODA"),DA(1),GMRGX(1),DA)) Q:DA'>0 D S6
|
---|
| 53 | K DA S DA=GMRGX("ODA") S:GMRGX("ODA1")'="@" DA(1)=GMRGX("ODA1") K GMRGX
|
---|
| 54 | Q
|
---|
| 55 | S6 I GMRGX("D") S $P(^GMRD(124.2,DA(1),1,DA,0),U,GMRGX("F")+1)=X F GMRGX=0:0 S GMRGX=$O(^DD(124.21,GMRGX("F"),1,GMRGX)) Q:GMRGX'>0 X:$D(^DD(124.21,GMRGX("F"),1,GMRGX,1)) ^(1)
|
---|
| 56 | I 'GMRGX("D") F GMRGX=0:0 S GMRGX=$O(^DD(124.21,GMRGX("F"),1,GMRGX)) Q:GMRGX'>0 X:$D(^DD(124.21,GMRGX("F"),1,GMRGX,2)) ^(2)
|
---|
| 57 | I 'GMRGX("D") S $P(^GMRD(124.2,DA(1),1,DA,0),U,GMRGX("F")+1)=""
|
---|
| 58 | Q
|
---|
| 59 | EN7 ; OLD XREF CALLED HERE. THIS ENTRY RETAINED FOR BACKWARD COMP.
|
---|
| 60 | G EN7^GMRGUT4
|
---|
| 61 | Q
|
---|