source: FOIAVistA/tag/r/TOOLKIT-AWCM-XD-XIN-XPAR-XQAB-XT-XUC-XUR-ZIN-ZTED/XQABERR.m@ 1154

Last change on this file since 1154 was 628, checked in by George Lilly, 15 years ago

initial load of FOIAVistA 6/30/08 version

File size: 2.7 KB
Line 
1XQABERR ;ISC-SF.SEA/JLI - TRACK ERRORS IN ALPHA/BETA ROUTINES BACK TO ISC ;7/23/93 12:49
2 ;;8.0;KERNEL;;Jul 10, 1995
3DOIT ;
4 S $P(XQASPAC," ",30)=" " S X="T",%DT="" D ^%DT S XQADT=+Y
5 F XQAAB=0:0 S XQAAB=$O(^XTV(8989.3,1,"ABPKG",XQAAB)) Q:XQAAB'>0 S XQAPK=+^(XQAAB,0),XQAAD=$P(^(0),U,3),XQAAD=$P(XQAAD,"@",2) I XQAAD'="" D
6 . S X=+$P(^XTV(8989.3,1,"ABPKG",XQAAB,0),U,5) S:X'>0 X=+$P(^(0),U,2) S $P(^(0),U,5)=XQADT
7 . D H^%DTC S XQALD=%H-1 D
8 .. K ^TMP($J) S XQALIN=1
9 .. X ^%ZOSF("UCI") S ^TMP($J,"A",XQALIN)=Y
10 .. F XQAK=0:0 S XQAK=$O(^XTV(8989.3,1,"ABPKG",XQAAB,1,XQAK)) Q:XQAK'>0 K XQASTR S XQASTR=^(XQAK,0) I XQASTR'="" D D T9
11 ... F XQAJ=0:0 S XQAJ=$O(^XTV(8989.3,1,"ABPKG",XQAAB,1,XQAK,1,XQAJ)) Q:XQAJ'>0 I $P(^(XQAJ,0),U)'="" S XQASTR(XQAJ)=$P(^(0),U)
12 . I XQALIN>1 D MAILIT
13 K %DT,%H,X,XMDUZ,XMSUB,XMTEXT,XMY,XQAA,XQAAB,XQAAD,XQAB,XQABY0,XQABYD,XQABYI,XQABYO,XQABYX,XQAD,XQADT,XQAI,XQAJ,XQAK,XQALD,XQALIN,XQAPK,XQASPAC,XQASTR,XQAX,XQAY,Y
14 Q
15T9 ;
16 K ^TMP("XQA",$J)
17 S XQADAT=XQALD F XQAI=0:0 S XQADAT=$O(^%ZTER(1,XQADAT)) Q:XQADAT'>0 F X=0:0 S X=$O(^%ZTER(1,XQADAT,1,X)) Q:X'>0 D
18 . K XQABY0 S XQABY0="" D S XQABY0=$P(XQABY0,U)
19 .. F XQAJ=0:0 S XQAJ=$O(^%ZTER(1,XQADAT,1,X,"ZV",XQAJ)) Q:XQAJ'>0 I $D(^(XQAJ,0)),$E(^(0),1,3)="XQY" S XQABYX=^(0) I $D(^("D")) S XQABYD=^("D") D Q:XQABY0'=""
20 ... I XQABYX="XQY",XQABYD'="",$D(^DIC(19,XQABYD,0)) S XQABY0(1)=$P(^(0),U) Q
21 ... I XQABYX="XQY0",XQABYD'="" S XQABY0=XQABYD
22 .. I XQABY0="",$D(XQABYO(1)) S XQABY0=XQABY0(1)
23 . I ^%ZTER(1,XQADAT,1,X,"ZE")[(U_XQASTR) S ^TMP("XQA",$J,XQADAT,X)=XQABY0 Q
24 . I $E(XQABY0,1,$L(XQASTR))=XQASTR S ^TMP("XQA",$J,XQADAT,X)=XQABY0 Q
25 F XQAI=0:0 S XQAI=$O(^TMP("XQA",$J,XQAI)) Q:XQAI'>0 F X=0:0 S X=$O(^TMP("XQA",$J,XQAI,X)) Q:X'>0 S XQADAT=XQAI,XQAD=0,XQAY=^(X) S:XQAY="" XQAY=" " D
26 . I ^%ZTER(1,XQADAT,1,X,"ZE")["," S XQAR=$P($P(^("ZE"),",",4),"-",4),XQAR=$P($P(^("ZE"),",",2),"-",3)_$S(XQAR="":"",1:"(")_XQAR_$S(XQAR="":"",1:")")
27 . S %H=XQADAT,XQAX=X D YMD^%DTC S XQAR(1)=X,X=XQAX
28 . I ^%ZTER(1,XQADAT,1,X,"ZE")["," S XQAR(2)="<"_XQAR_">"_$P(^%ZTER(1,XQADAT,1,X,"ZE"),",",1)_" "
29 . I ^%ZTER(1,XQADAT,1,X,"ZE")'["," S XQAR(2)=^("ZE")
30 . Q:XQAR(2)'[(U_XQASTR)&($E(XQAY,1,$L(XQASTR))'=XQASTR) S ^(XQAR(1))=$G(^TMP($J,"B",XQASTR,XQAR(2),XQAY,XQAR(1)))+1
31 S XQAA=""
32 F S XQAA=$O(^TMP($J,"B",XQASTR,XQAA)) Q:XQAA="" S XQAY="" F S XQAY=$O(^TMP($J,"B",XQASTR,XQAA,XQAY)) Q:XQAY="" F XQAD=0:0 S XQAD=$O(^TMP($J,"B",XQASTR,XQAA,XQAY,XQAD)) Q:XQAD'>0 D
33 . S XQALIN=XQALIN+1,XQAB=XQAA_U S:$L(XQAB)<31 XQAB=$E(XQAB_XQASPAC,1,31) S ^TMP($J,"A",XQALIN)=XQAB_" "_XQAD_" "_^(XQAD)_$S(XQAY'=" ":" "_XQAY,1:"")
34Z Q
35 ;
36MAILIT ;
37 S XMY("S.XQAB ERROR LOG SERVER@"_XQAAD)="",XMSUB="ALPHA/BETA TEST ERRORS LOGGED ",XMTEXT="^TMP($J,""A"",",XMDUZ=.5 D ^XMD
38 Q
Note: See TracBrowser for help on using the repository browser.