BCHEXRST ; IHS/CMI/LAB - RESET TX LOG AUGUST 14, 1992 ;
;;2.0;IHS RPMS CHR SYSTEM;;OCT 23, 2012;Build 27
W !!,"This routine will reset the CHR Data Transmission Log. You must be",!,"absolutely sure that you have corrected the underlying problem that caused ","the Transmission process to fail in the first place!",!!
W "The CHR Data Transmission log entry you choose will be REMOVED from the log",!,"file and all Utility and Data globals associated with that run will be killed!!",!!
W "You must now select the Log Entry to be RESET. <<< SELECT CAREFULLY >>>",!
S DIC="^BCHXLOG(",DIC(0)="AEMQ",DIC("S")="I $P(^BCHXLOG(Y,0),U,15)'=""C"",$P(^BCHXLOG(Y,0),U,15)'=""P""" D ^DIC K DIC I Y=-1 W !!,"Goodbye" G EOJ
S BCHDFN=+Y
D DISP
S DIR(0)="Y",DIR("A")="Are you sure you want to do this",DIR("B")="N" D ^DIR K DIR S:$D(DUOUT) DIRUT=1
I Y'=1 D EOJ Q
DIK ;
S DA=BCHDFN,DIK="^BCHXLOG(" D ^DIK
K ^TMP("BCHDR"),^TMP("BCHREDO"),^BCHRDATA ;UNSUBSCRIPTED VARIABLES KILLED - THESE ARE CMB STANDARD DEFINED SCRATCH GLOBALS FOR TRANSMITTING DATA TO DATA CENTER
S X=$P(^BCHSITE(DUZ(2),0),U,11) I X S X=X-1,DIE="^BCHSITE(",DA=DUZ(2),DR=".11///"_X D ^DIE K DIE,DA,DR
D EOJ
Q
DISP ;
DIQ ; CALL TO DIQ
W !!,"Information for Log Entry ",BCHDFN,!
S DIC="^BCHXLOG(",DA=BCHDFN,DR="0;11",DIQ(0)="C" D EN^DIQ
K DIC,DIQ,DR,DA
Q
EOJ ;
K DA,DIK,BCHDFN,Y,X,DIR,DIRUT
Q
BCHEXRST ; IHS/CMI/LAB - RESET TX LOG AUGUST 14, 1992 ;
+1 ;;2.0;IHS RPMS CHR SYSTEM;;OCT 23, 2012;Build 27
+2 WRITE !!,"This routine will reset the CHR Data Transmission Log. You must be",!,"absolutely sure that you have corrected the underlying problem that caused ","the Transmission process to fail in the first place!",!!
+3 WRITE "The CHR Data Transmission log entry you choose will be REMOVED from the log",!,"file and all Utility and Data globals associated with that run will be killed!!",!!
+4 WRITE "You must now select the Log Entry to be RESET. <<< SELECT CAREFULLY >>>",!
+5 SET DIC="^BCHXLOG("
SET DIC(0)="AEMQ"
SET DIC("S")="I $P(^BCHXLOG(Y,0),U,15)'=""C"",$P(^BCHXLOG(Y,0),U,15)'=""P"""
DO ^DIC
KILL DIC
IF Y=-1
WRITE !!,"Goodbye"
GOTO EOJ
+6 SET BCHDFN=+Y
+7 DO DISP
+8 SET DIR(0)="Y"
SET DIR("A")="Are you sure you want to do this"
SET DIR("B")="N"
DO ^DIR
KILL DIR
IF $DATA(DUOUT)
SET DIRUT=1
+9 IF Y'=1
DO EOJ
QUIT
DIK ;
+1 SET DA=BCHDFN
SET DIK="^BCHXLOG("
DO ^DIK
+2 ;UNSUBSCRIPTED VARIABLES KILLED - THESE ARE CMB STANDARD DEFINED SCRATCH GLOBALS FOR TRANSMITTING DATA TO DATA CENTER
KILL ^TMP("BCHDR"),^TMP("BCHREDO"),^BCHRDATA
+3 SET X=$PIECE(^BCHSITE(DUZ(2),0),U,11)
IF X
SET X=X-1
SET DIE="^BCHSITE("
SET DA=DUZ(2)
SET DR=".11///"_X
DO ^DIE
KILL DIE,DA,DR
+4 DO EOJ
+5 QUIT
DISP ;
DIQ ; CALL TO DIQ
+1 WRITE !!,"Information for Log Entry ",BCHDFN,!
+2 SET DIC="^BCHXLOG("
SET DA=BCHDFN
SET DR="0;11"
SET DIQ(0)="C"
DO EN^DIQ
+3 KILL DIC,DIQ,DR,DA
+4 QUIT
EOJ ;
+1 KILL DA,DIK,BCHDFN,Y,X,DIR,DIRUT
+2 QUIT