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

BKMRMDR.m

Go to the documentation of this file.
BKMRMDR ;VNGT/HS/ALA-HIV STI Reminders ; 28 Feb 2007  11:07 AM
 ;;2.2;HIV MANAGEMENT SYSTEM;;Apr 01, 2015;Build 40
 ;
 ;
EN(BKDFN,BKBDT,BKEDT,BKTYP,ARRAY,VALUE) ; PEP
 ; Return STI (Sexually Transmitted Infections) incidences
 ; Can specify a particular one or get all or key
 ;
 ;Input
 ;  BKDFN - Patient ien
 ;  BKBDT - Beginning Date Range
 ;  BKEDT - Ending Date Range
 ;  BKTYP - Type of reminder
 ;
 S BKTYP=$G(BKTYP,""),BKBDT=$G(BKBDT,""),BKEDT=$G(BKEDT,DT)
 K ARRAY
 I BKTYP="" D ALL G DONE
 I BKTYP="KEY" D KEY G DONE
 I BKTYP="OTHER" D OTH G DONE
 I BKTYP="CHN"!(BKTYP="Chancroid") D CHN(.BKDFN,.BKBDT,.BKEDT,"CHN",.ARRAY)
 I BKTYP="CHL"!(BKTYP="Chlamydia") D CHL(.BKDFN,.BKBDT,.BKEDT,"CHL",.ARRAY)
 I BKTYP="GENH"!(BKTYP="Genital Herpes") D GENH(.BKDFN,.BKBDT,.BKEDT,"GENH",.ARRAY)
 I BKTYP="GENW"!(BKTYP="Genital Warts") D GENW(.BKDFN,.BKBDT,.BKEDT,"GENW",.ARRAY)
 I BKTYP="GC"!(BKTYP="Gonorrhea") D GON(.BKDFN,.BKBDT,.BKEDT,"GC",.ARRAY)
 I BKTYP="HEPB"!(BKTYP="Hepatitis B") D HEPB(.BKDFN,.BKBDT,.BKEDT,"HEPB",.ARRAY)
 I BKTYP="HEPC"!(BKTYP="Hepatitis C") D HEPC(.BKDFN,.BKBDT,.BKEDT,"HEPC",.ARRAY)
 I BKTYP="HIV"!(BKTYP="HIV/AIDS") D HIV(.BKDFN,.BKBDT,.BKEDT,"HIV",.ARRAY)
 I BKTYP="HPV"!(BKTYP="Human Papilloma Virus") D HPV(.BKDFN,.BKBDT,.BKEDT,"HPV",.ARRAY)
 I BKTYP="LGV"!(BKTYP="Lymphogranuloma Venereum") D LGV(.BKDFN,.BKBDT,.BKEDT,"LGV",.ARRAY)
 I BKTYP="SYP"!(BKTYP="Syphilis") D SYP(.BKDFN,.BKBDT,.BKEDT,"SYP",.ARRAY)
 I BKTYP="TRIC"!(BKTYP="Trichomonas") D TRIC(.BKDFN,.BKBDT,.BKEDT,"TRIC",.ARRAY)
 ;
DONE ;
 NEW TYP,TOTAL,DX,DAT,RETURN,DTDIF
 ;
 S TYP=""
 F  S TYP=$O(ARRAY(TYP)) Q:TYP=""  D
 . S TOTAL=0,DAT="",IDXDT=$O(ARRAY(TYP,"")),RETURN=""
 . S TOTAL=0,DAT="",RETURN=""
 . F  S DAT=$O(ARRAY(TYP,DAT)) Q:'DAT  D
 .. S TOTAL=TOTAL+1
 .. S VALUE(TYP,"DEN",DAT)=ARRAY(TYP,DAT)
 .. S RETURN=RETURN_$$FMTE^XLFDT(DAT,"2Z")_" "_ARRAY(TYP,DAT)_"; "
 . S VALUE(TYP,"DEN")=TOTAL_U_RETURN
 Q
 ;
CHN(BKDFN,BKBDT,BKEDT,BKTYP,ARRAY) ; Chancroid
 NEW TIEN
 K ^TMP("BKMARRAY",$J)
 D BLDTAX^BKMIXX5("BKM CHANCROID DXS","^TMP(""BKMARRAY"",$J)")
 D FND(.BKDFN,.BKBDT,.BKEDT,.BKTYP,.ARRAY)
 K ^TMP("BKMARRAY",$J)
 Q
 S TIEN=""
 F  S TIEN=$O(^TMP("BKMARRAY",$J,TIEN)) Q:TIEN=""  D
 . D FND1(.TIEN,.BKDFN,.BKBDT,.BKEDT,.BKTYP,.ARRAY)
 K ^TMP("BKMARRAY",$J)
 Q
 ;
CHL(BKDFN,BKBDT,BKEDT,BKTYP,ARRAY) ; Chlamydia
 NEW TIEN
 K ^TMP("BKMARRAY",$J)
 D BLDTAX^BKMIXX5("BKM CHLAMYDIA DXS","^TMP(""BKMARRAY"",$J)")
 D FND(.BKDFN,.BKBDT,.BKEDT,.BKTYP,.ARRAY)
 K ^TMP("BKMARRAY",$J)
 Q
 S TIEN=""
 F  S TIEN=$O(^TMP("BKMARRAY",$J,TIEN)) Q:TIEN=""  D
 . D FND1(.TIEN,.BKDFN,.BKBDT,.BKEDT,.BKTYP,.ARRAY)
 K ^TMP("BKMARRAY",$J)
 Q
 ;
GENH(BKDFN,BKBDT,BKEDT,BKTYP,ARRAY) ; Genital Herpes
 NEW TIEN
 K ^TMP("BKMARRAY",$J)
 D BLDTAX^BKMIXX5("BKM GENITAL HERPES DXS","^TMP(""BKMARRAY"",$J)")
 D FND(.BKDFN,.BKBDT,.BKEDT,.BKTYP,.ARRAY)
 K ^TMP("BKMARRAY",$J)
 Q
 S TIEN=""
 F  S TIEN=$O(^TMP("BKMARRAY",$J,TIEN)) Q:TIEN=""  D
 . D FND1(.TIEN,.BKDFN,.BKBDT,.BKEDT,.BKTYP,.ARRAY)
 K ^TMP("BKMARRAY",$J)
 Q
 ;
GENW(BKDFN,BKBDT,BKEDT,BKTYP,ARRAY) ; Genital Warts
 NEW TIEN
 K ^TMP("BKMARRAY",$J)
 D BLDTAX^BKMIXX5("BKM GENITAL WARTS DXS","^TMP(""BKMARRAY"",$J)")
 D FND(.BKDFN,.BKBDT,.BKEDT,.BKTYP,.ARRAY)
 K ^TMP("BKMARRAY",$J)
 Q
 S TIEN=""
 F  S TIEN=$O(^TMP("BKMARRAY",$J,TIEN)) Q:TIEN=""  D
 . D FND1(.TIEN,.BKDFN,.BKBDT,.BKEDT,.BKTYP,.ARRAY)
 K ^TMP("BKMARRAY",$J)
 Q
 ;
GON(BKDFN,BKBDT,BKEDT,BKTYP,ARRAY) ; Gonorrhea
 NEW TIEN
 K ^TMP("BKMARRAY",$J)
 D BLDTAX^BKMIXX5("BKM GONORRHEA DXS","^TMP(""BKMARRAY"",$J)")
 D FND(.BKDFN,.BKBDT,.BKEDT,.BKTYP,.ARRAY)
 K ^TMP("BKMARRAY",$J)
 Q
 S TIEN=""
 F  S TIEN=$O(^TMP("BKMARRAY",$J,TIEN)) Q:TIEN=""  D
 . D FND1(.TIEN,.BKDFN,.BKBDT,.BKEDT,.BKTYP,.ARRAY)
 K ^TMP("BKMARRAY",$J)
 Q
 ;
HEPB(BKDFN,BKBDT,BKEDT,BKTYP,ARRAY) ;  Hepatitis B
 NEW TIEN
 K ^TMP("BKMARRAY",$J)
 D BLDTAX^BKMIXX5("BKM HEP B DXS","^TMP(""BKMARRAY"",$J)")
 D FND(.BKDFN,.BKBDT,.BKEDT,.BKTYP,.ARRAY)
 K ^TMP("BKMARRAY",$J)
 Q
 S TIEN=""
 F  S TIEN=$O(^TMP("BKMARRAY",$J,TIEN)) Q:TIEN=""  D
 . D FND1(.TIEN,.BKDFN,.BKBDT,.BKEDT,.BKTYP,.ARRAY)
 K ^TMP("BKMARRAY",$J)
 Q
 ;
HEPC(BKDFN,BKBDT,BKEDT,BKTYP,ARRAY) ;  Hepatitis C
 NEW TIEN
 K ^TMP("BKMARRAY",$J)
 D BLDTAX^BKMIXX5("BKM HEP C DXS","^TMP(""BKMARRAY"",$J)")
 D FND(.BKDFN,.BKBDT,.BKEDT,.BKTYP,.ARRAY)
 K ^TMP("BKMARRAY",$J)
 Q
 S TIEN=""
 F  S TIEN=$O(^TMP("BKMARRAY",$J,TIEN)) Q:TIEN=""  D
 . D FND1(.TIEN,.BKDFN,.BKBDT,.BKEDT,.BKTYP,.ARRAY)
 K ^TMP("BKMARRAY",$J)
 Q
 ;
HIV(BKDFN,BKBDT,BKEDT,BKTYP,ARRAY) ;  HIV/AIDS
 NEW TIEN
 K ^TMP("BKMARRAY",$J)
 D BLDTAX^BKMIXX5("BGP HIV/AIDS DXS","^TMP(""BKMARRAY"",$J)")
 D FND(.BKDFN,.BKBDT,.BKEDT,.BKTYP,.ARRAY)
 K ^TMP("BKMARRAY",$J)
 Q
 S TIEN=""
 F  S TIEN=$O(^TMP("BKMARRAY",$J,TIEN)) Q:TIEN=""  D
 . D FND1(.TIEN,.BKDFN,.BKBDT,.BKEDT,.BKTYP,.ARRAY)
 K ^TMP("BKMARRAY",$J)
 Q
 ;
HPV(BKDFN,BKBDT,BKEDT,BKTYP,ARRAY) ; Human Papilloma Virus
 NEW TIEN
 K ^TMP("BKMARRAY",$J)
 D BLDTAX^BKMIXX5("BKM HPV DXS","^TMP(""BKMARRAY"",$J)")
 D FND(.BKDFN,.BKBDT,.BKEDT,.BKTYP,.ARRAY)
 K ^TMP("BKMARRAY",$J)
 Q
 S TIEN=""
 F  S TIEN=$O(^TMP("BKMARRAY",$J,TIEN)) Q:TIEN=""  D
 . D FND1(.TIEN,.BKDFN,.BKBDT,.BKEDT,.BKTYP,.ARRAY)
 K ^TMP("BKMARRAY",$J)
 Q
 ;
LGV(BKDFN,BKBDT,BKEDT,BKTYP,ARRAY) ; Lymphogranuloma Venereum
 NEW TIEN
 K ^TMP("BKMARRAY",$J)
 D BLDTAX^BKMIXX5("BKM LGV DXS","^TMP(""BKMARRAY"",$J)")
 D FND(.BKDFN,.BKBDT,.BKEDT,.BKTYP,.ARRAY)
 K ^TMP("BKMARRAY",$J)
 Q
 S TIEN=""
 F  S TIEN=$O(^TMP("BKMARRAY",$J,TIEN)) Q:TIEN=""  D
 . D FND1(.TIEN,.BKDFN,.BKBDT,.BKEDT,.BKTYP,.ARRAY)
 K ^TMP("BKMARRAY",$J)
 Q
 ;
SYP(BKDFN,BKBDT,BKEDT,BKTYP,ARRAY) ; Syphilis
 NEW TIEN
 K ^TMP("BKMARRAY",$J)
 D BLDTAX^BKMIXX5("BKM SYPHILIS DXS","^TMP(""BKMARRAY"",$J)")
 D FND(.BKDFN,.BKBDT,.BKEDT,.BKTYP,.ARRAY)
 K ^TMP("BKMARRAY",$J)
 Q
 S TIEN=""
 F  S TIEN=$O(^TMP("BKMARRAY",$J,TIEN)) Q:TIEN=""  D
 . D FND1(.TIEN,.BKDFN,.BKBDT,.BKEDT,.BKTYP,.ARRAY)
 K ^TMP("BKMARRAY",$J)
 Q
 ;
TRIC(BKDFN,BKBDT,BKEDT,BKTYP,ARRAY) ; Trichomonas
 NEW TIEN
 K ^TMP("BKMARRAY",$J)
 D BLDTAX^BKMIXX5("BKM TRICHOMONIASIS DXS","^TMP(""BKMARRAY"",$J)")
 D FND(.BKDFN,.BKBDT,.BKEDT,.BKTYP,.ARRAY)
 K ^TMP("BKMARRAY",$J)
 Q
 S TIEN=""
 F  S TIEN=$O(^TMP("BKMARRAY",$J,TIEN)) Q:TIEN=""  D
 . D FND1(.TIEN,.BKDFN,.BKBDT,.BKEDT,.BKTYP,.ARRAY)
 K ^TMP("BKMARRAY",$J)
 Q
 ;
HIVE(BKDFN,BKIDT,BKMEDT) ;EP - HIV/AIDs ever
 NEW TIEN,BKMBDT,QFL,IEN,VISIT,VSDT,LDATE,LV
 K ^TMP("BKMARRAY",$J)
 D BLDTAX^BKMIXX5("BGP HIV/AIDS DXS","^TMP(""BKMARRAY"",$J)")
 ;
 NEW BKMBDT,IEN
 S BKMBDT=$S(BKIDT'="":(9999999-BKIDT)+.0001,1:"")
 S BKMEDT=(9999999-BKMEDT)
 F  S BKMBDT=$O(^AUPNVPOV("AA",BKDFN,BKMBDT),-1) Q:BKMBDT=""!(BKMBDT\1<BKMEDT)  D  Q:QFL
 . S IEN="",QFL=0
 . F  S IEN=$O(^AUPNVPOV("AA",BKDFN,BKMBDT,IEN)) Q:IEN=""  D  Q:QFL
 .. S TIEN=$$GET1^DIQ(9000010.07,IEN_",",.01,"I") I TIEN="" Q
 .. I '$D(^TMP("BKMARRAY",$J,TIEN)) Q
 .. S VISIT=$$GET1^DIQ(9000010.07,IEN_",",.03,"I") Q:VISIT=""
 .. S VSDT=$$GET1^DIQ(9000010,VISIT_",",.01,"I")\1 Q:VSDT=0
 .. S QFL=1,LDATE=VSDT,LV=IEN
 .. S VALUE(BKTY,"NUM",BKNMTY,VSDT)=1_U_$$FMTE^XLFDT((LDATE\1),"2Z")_" POV: HIV ["_^TMP("BKMARRAY",$J,TIEN)_"]"
 .. S HVDFL=1
 ;
 ;Check CPT
 K ^TMP("BKMARRAY",$J)
 D BLDTAX^BKMIXX5("BGP CPT HIV TESTS","^TMP(""BKMARRAY"",$J)")
 S TIEN="",QFL=0
 F  S TIEN=$O(^TMP("BKMARRAY",$J,TIEN)) Q:TIEN=""  D  Q:QFL
 . S BKMBDT=$S(BKIDT'="":(9999999-BKIDT)+.0001,1:"")
 . F  S BKMBDT=$O(^AUPNVCPT("AA",BKDFN,TIEN,BKMBDT),-1) Q:BKMBDT=""!(BKMBDT\1<BKMEDT)  D  Q:QFL
 .. S IEN=""
 .. F  S IEN=$O(^AUPNVCPT("AA",BKDFN,TIEN,BKMBDT,IEN)) Q:IEN=""  D  Q:QFL
 ... S VISIT=$$GET1^DIQ(9000010.18,IEN_",",.03,"I") Q:VISIT=""
 ... S VSDT=$$GET1^DIQ(9000010,VISIT_",",.01,"I")\1 Q:VSDT=0
 ... S QFL=1,LDATE=VSDT,LV=IEN
 ... S VALUE(BKTY,"NUM",BKNMTY,VSDT)=1_U_$$FMTE^XLFDT((LDATE\1),"2Z")_" CPT: HIV ["_^TMP("BKMARRAY",$J,TIEN)_"]"
 ... S HVDFL=1
 Q
 ; using new future cross-reference
 S TIEN=""
 F  S TIEN=$O(^TMP("BKMARRAY",$J,TIEN)) Q:TIEN=""  D
 . S BKMBDT=""
 . F  S BKMBDT=$O(^AUPNVPOV("AF",TIEN,BKMBDT)) Q:BKMBDT=""!(BKMBDT\1>BKMEDT)  D
 . S IEN=""
 . F  S IEN=$O(^AUPNVPOV("AF",TIEN,BKMBDT,BKDFN,IEN)) Q:IEN=""  D  Q:QFL
 .. S VISIT=$$GET1^DIQ(9000010.07,IEN_",",.03,"I") Q:VISIT=""
 .. S VSDT=$$GET1^DIQ(9000010,VISIT_",",.01,"I")\1 Q:VSDT=0
 .. S QFL=1,LDATE=VSDT,LV=IEN
 .. S VALUE(BKTY,"NUM",BKNMTY)=1_U_$$FMTE^XLFDT((LDATE\1),"2Z")_" [HIV "_^TMP("BKMARRAY",$J,TIEN)_"]"
 .. S HVDFL=1
 Q
 ;
ALL ; Get all STDs
 D CHN(.BKDFN,.BKBDT,.BKEDT,"CHN",.ARRAY)
 D CHL(.BKDFN,.BKBDT,.BKEDT,"CHL",.ARRAY)
 D GENH(.BKDFN,.BKBDT,.BKEDT,"GENH",.ARRAY)
 D GENW(.BKDFN,.BKBDT,.BKEDT,"GENW",.ARRAY)
 D GON(.BKDFN,.BKBDT,.BKEDT,"GC",.ARRAY)
 D HEPB(.BKDFN,.BKBDT,.BKEDT,"HEPB",.ARRAY)
 D HEPC(.BKDFN,.BKBDT,.BKEDT,"HEPC",.ARRAY)
 D HIV(.BKDFN,.BKBDT,.BKEDT,"HIV",.ARRAY)
 D HPV(.BKDFN,.BKBDT,.BKEDT,"HPV",.ARRAY)
 D LGV(.BKDFN,.BKBDT,.BKEDT,"LGV",.ARRAY)
 D SYP(.BKDFN,.BKBDT,.BKEDT,"SYP",.ARRAY)
 D TRIC(.BKDFN,.BKBDT,.BKEDT,"TRIC",.ARRAY)
 Q
 ;
KEY ; Get all Key STDs
 D CHL(.BKDFN,.BKBDT,.BKEDT,"CHL",.ARRAY)
 D GON(.BKDFN,.BKBDT,.BKEDT,"GC",.ARRAY)
 D HIV(.BKDFN,.BKBDT,.BKEDT,"HIV",.ARRAY)
 D SYP(.BKDFN,.BKBDT,.BKEDT,"SYP",.ARRAY)
 Q
 ;
OTH ; Other than the Key STIs
 D CHN(.BKDFN,.BKBDT,.BKEDT,"CHN",.ARRAY)
 D GENH(.BKDFN,.BKBDT,.BKEDT,"GENH",.ARRAY)
 D GENW(.BKDFN,.BKBDT,.BKEDT,"GENW",.ARRAY)
 D HEPB(.BKDFN,.BKBDT,.BKEDT,"HEPB",.ARRAY)
 D HEPC(.BKDFN,.BKBDT,.BKEDT,"HEPC",.ARRAY)
 D HPV(.BKDFN,.BKBDT,.BKEDT,"HPV",.ARRAY)
 D LGV(.BKDFN,.BKBDT,.BKEDT,"LGV",.ARRAY)
 D TRIC(.BKDFN,.BKBDT,.BKEDT,"TRIC",.ARRAY)
 Q
 ;
FND(BKDFN,BKBDT,BKEDT,BKTYP,ARRAY) ;  Find an entry
 NEW BKMBDT,IEN
 S BKMBDT=BKBDT,BKMEDT=(9999999-BKEDT)
 ;
 S BKMBDT=(9999999-BKBDT)+.0001
 F  S BKMBDT=$O(^AUPNVPOV("AA",BKDFN,BKMBDT),-1) Q:BKMBDT=""!(BKMBDT\1<BKMEDT)  D
 . S IEN=""
 . F  S IEN=$O(^AUPNVPOV("AA",BKDFN,BKMBDT,IEN)) Q:IEN=""  D
 .. S TIEN=$$GET1^DIQ(9000010.07,IEN_",",.01,"I") I TIEN="" Q
 .. I '$D(^TMP("BKMARRAY",$J,TIEN)) Q
 .. S VISIT=$$GET1^DIQ(9000010.07,IEN_",",.03,"I") Q:VISIT=""
 .. S VSDT=$$GET1^DIQ(9000010,VISIT_",",.01,"I")\1 Q:VSDT=0
 .. S ARRAY(BKTYP,VSDT)="POV: "_BKTYP_" "_^TMP("BKMARRAY",$J,TIEN)
 .. S ZARRAY("ZD",VSDT,BKTYP)="",ZARRAY("ZD",VSDT)=$G(ZARRAY("ZD",VSDT))+1
 Q
 ;
FND1(TIEN,BKDFN,BKBDT,BKEDT,BKTYP,ARRAY) ; using new future cross-reference
 NEW DXC
 F  S BKMBDT=$O(^AUPNVPOV("AF",TIEN,BKMBDT)) Q:BKMBDT=""!(BKMBDT\1<BKEDT)  D
 . S IEN=""
 . F  S IEN=$O(^AUPNVPOV("AF",TIEN,BKMBDT,BKDFN,IEN)) Q:IEN=""  D
 .. S DXC=^TMP("BKMARRAY",$J,TIEN),VSDT=BKMBDT\1
 .. S ARRAY(BKTYP,VSDT)="POV: "_BKTYP_" "_DXC
 ;
 Q
 ;
HIVS(BKDFN,BKIDT,BKMEDT) ;EP - HIV/AIDs between date range
 NEW TIEN
 K ^TMP("BKMARRAY",$J)
 D BLDTAX^BKMIXX5("BGP HIV/AIDS DXS","^TMP(""BKMARRAY"",$J)")
 ;
 S FLAG=0
 NEW BKMBDT,IEN
 S BKMBDT=$S(BKIDT'="":(9999999-BKIDT)+.0001,1:"")
 S BKMEDT=(9999999-BKMEDT)
 F  S BKMBDT=$O(^AUPNVPOV("AA",BKDFN,BKMBDT),-1) Q:BKMBDT=""!(BKMBDT\1<BKMEDT)  D  Q:QFL
 . S IEN="",QFL=0
 . F  S IEN=$O(^AUPNVPOV("AA",BKDFN,BKMBDT,IEN)) Q:IEN=""  D  Q:QFL
 .. S TIEN=$$GET1^DIQ(9000010.07,IEN_",",.01,"I") I TIEN="" Q
 .. I '$D(^TMP("BKMARRAY",$J,TIEN)) Q
 .. S VISIT=$$GET1^DIQ(9000010.07,IEN_",",.03,"I") Q:VISIT=""
 .. S VSDT=$$GET1^DIQ(9000010,VISIT_",",.01,"I")\1 Q:VSDT=0
 .. S FLAG=1_U_$$FMTE^XLFDT(VSDT,"2Z")_" POV: HIV ["_^TMP("BKMARRAY",$J,TIEN)_"]",QFL=1
 K ^TMP("BKMARRAY",$J)
 D BLDTAX^BKMIXX5("BGP CPT HIV TESTS","^TMP(""BKMARRAY"",$J)")
 S TIEN="",QFL=0
 F  S TIEN=$O(^TMP("BKMARRAY",$J,TIEN)) Q:TIEN=""  D  Q:QFL
 . S BKMBDT=$S(BKIDT'="":(9999999-BKIDT)+.0001,1:"")
 . F  S BKMBDT=$O(^AUPNVCPT("AA",BKDFN,TIEN,BKMBDT),-1) Q:BKMBDT=""!(BKMBDT\1<BKMEDT)  D  Q:QFL
 .. S IEN=""
 .. F  S IEN=$O(^AUPNVCPT("AA",BKDFN,TIEN,BKMBDT,IEN)) Q:IEN=""  D  Q:QFL
 ... S VISIT=$$GET1^DIQ(9000010.18,IEN_",",.03,"I") Q:VISIT=""
 ... S VSDT=$$GET1^DIQ(9000010,VISIT_",",.01,"I")\1 Q:VSDT=0
 ... S FLAG=1_U_$$FMTE^XLFDT(VSDT,"2Z")_" CPT: HIV ["_^TMP("BKMARRAY",$J,TIEN)_"]"_U_VSDT,QFL=1
 K ^TMP("BKMARRAY",$J)
 Q FLAG