AUPNMSP ; IHS/SD/SDR - X-REFS FOR MSP PATIENT FILE ; [ 04/14/2004 11:26 AM ]
;;99.1;IHS DICTIONARIES (PATIENT);**8,9,10,13**;APR 14, 2004;Build 9
EN(AUPNPAT,AGIEN) ;ENTRY POINT
; AUPNPAT- Patient IEN
; AGIEN - IEN for MSP Patient file
;set for x-ref
S ^AUPNMSP("C",AUPNPAT,$P(^AUPNMSP(AGIEN,0),"^",1),AGIEN)=""
Q
;AUP99.1*13 IHS/SD/TPF 4/14/2004
KILL(AUPNPAT,AGIEN) ; EP - KILL "C" XREF
K ^AUPNMSP("C",AUPNPAT,$P(^AUPNMSP(AGIEN,0),"^",1),AGIEN)
Q
;kill/clean-up for x-ref
;S AGDT=""
;F S AGDT=$O(^AUPNMSP("C",AUPNPAT,AGDT)) Q:AGDT="" D
;.S AGIEN=""
;F S AGIEN=$O(^AUPNMSP("C",AUPNPAT,AGDT,AGIEN)) Q:AGIEN="" D
;..S AGT=AGIEN
;..S AGTEST=$P($G(^AUPNMSP(AGIEN,0)),"^")
;..I AGTEST'=AGDT D
;...K ^AUPNMSP("C",AUPNPAT,AGDT,AGIEN)
Q
AUPNMSP ; IHS/SD/SDR - X-REFS FOR MSP PATIENT FILE ; [ 04/14/2004 11:26 AM ]
+1 ;;99.1;IHS DICTIONARIES (PATIENT);**8,9,10,13**;APR 14, 2004;Build 9
EN(AUPNPAT,AGIEN) ;ENTRY POINT
+1 ; AUPNPAT- Patient IEN
+2 ; AGIEN - IEN for MSP Patient file
+3 ;set for x-ref
+4 SET ^AUPNMSP("C",AUPNPAT,$PIECE(^AUPNMSP(AGIEN,0),"^",1),AGIEN)=""
+5 QUIT
+6 ;AUP99.1*13 IHS/SD/TPF 4/14/2004
KILL(AUPNPAT,AGIEN) ; EP - KILL "C" XREF
+1 KILL ^AUPNMSP("C",AUPNPAT,$PIECE(^AUPNMSP(AGIEN,0),"^",1),AGIEN)
+2 QUIT
+3 ;kill/clean-up for x-ref
+4 ;S AGDT=""
+5 ;F S AGDT=$O(^AUPNMSP("C",AUPNPAT,AGDT)) Q:AGDT="" D
+6 ;.S AGIEN=""
+7 ;F S AGIEN=$O(^AUPNMSP("C",AUPNPAT,AGDT,AGIEN)) Q:AGIEN="" D
+8 ;..S AGT=AGIEN
+9 ;..S AGTEST=$P($G(^AUPNMSP(AGIEN,0)),"^")
+10 ;..I AGTEST'=AGDT D
+11 ;...K ^AUPNMSP("C",AUPNPAT,AGDT,AGIEN)
+12 QUIT