source: FOIAVistA/trunk/r/INCOME_VERIFICATION_MATCH-IVM/IVMPBUL.m@ 1397

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

initial load of FOIAVistA 6/30/08 version

File size: 2.3 KB
Line 
1IVMPBUL ;BAJ - HL7 Z07 CONSISTENCY CHECKER -- BULLETIN ; 10/20/05 11:48am
2 ;;2.0;INCOME VERIFICATION MATCH;**105**;JUL 8,1996;Build 2
3 ;
4 ; this routine will send a bulletin for a specified condition
5 ;
6EN ; entry point
7 N DGB,DGTEXT,XMDUZ,XMSUB,DGSM,XMY,XMTEXT
8 ;
9 ; type = Type of Bulletin to send
10 ;
11 D CC ; assemble arrays and variables for bulletin
12 S DGB=6 D BUL ; send bulletin and quit
13 Q
14 ;
15CC ; Consistency check bulletin
16 ; This bulletin will be sent for Z07 Consistency check process
17 ; it indicates the number of records sent and the number not sent
18 ; and instructions for further action
19 ;
20 N DGSEND,DGSENX,DGTOT,DGC,I,J
21 I '$D(^TMP($J,"CC")) Q
22 S DGSEND=^TMP($J,"CC",1),DGSENX=^TMP($J,"CC",0),DGTOT=DGSEND+DGSENX
23 S XMDUZ="IVM BACKGROUND JOB"
24 S XMSUB="HEC INCONSISTENCY TRANSMISSIONS" F I=1:1 S J=$P($T(BT+I),";;",2) Q:J="QUIT" S DGTEXT(I,0)=J,DGC=I
25 S DGC=DGC+1,DGTEXT(DGC,0)=""
26 S DGC=DGC+1,DGTEXT(DGC,0)=" Z07 MESSAGES SENT: "_$J(DGSEND,10)
27 S DGC=DGC+1,DGTEXT(DGC,0)=" Z07 MESSAGES NOT SENT: "_$J(DGSENX,10)
28 S DGC=DGC+1,DGTEXT(DGC,0)=""
29 Q
30 ;
31BT ; ** Bulletin Text -- Line offset is called to assemble message ***
32 ;;Following is a summary of the inconsistent data check performed during
33 ;;the nightly process to transmit patient data to the HEC. The number NOT
34 ;;SENT, indicates the number of Z07 messages that were not transmitted due
35 ;;to data inconsistencies. These Z07 messages will not be sent until the
36 ;;inconsistencies are corrected. For details, run the Inconsistent Data
37 ;;Elements Report in the ADT Outputs Menu.
38 ;;
39 ;;QUIT
40BUL ; create and transmit bulletin
41 ;
42 N DIC,DIX,DIY,DO,DD
43 I '$D(DGB),'$D(XMSUB) Q
44 K:$D(DGTEXT) XMTEXT I '$D(DGTEXT)&('$D(XMTEXT)) Q
45 S DGB=+$P($G(^DG(43,1,"NOT")),"^",DGB)
46 I '$D(^XMB(3.8,DGB,0)) Q
47 ;
48 ;Protect Fileman from Mailman call
49 N DICRREC,DIDATA,DIEFAR,DIEFCNOD,DIEFDAS,DIEFECNT,DIEFF,DIEFFLAG
50 N DIEFFLD,DIEFFLST,DIEFFREF,DIEFFVAL,DIEFFXR,DIEFI,DIEFIEN,DIEFLEV
51 N DIEFNODE,DIEFNVAL,DIEFOUT,DIEFOVAL,DIEFRFLD,DIEFRLST,DIEFSORK
52 N DIEFSPOT,DIEFTMP,DIEFTREF,DIFLD,DIFM,DIQUIET,DISYS,D,D0,DA
53 ;
54 S XMY("G."_$P($G(^XMB(3.8,DGB,0)),"^",1))="" ; pass mailgroup
55 Q:'$D(DUZ) S:'$D(DGSM) DGSM=1
56 S XMTEXT=$S('$D(XMTEXT):"DGTEXT(",1:XMTEXT)
57 S:$D(DUZ)#2&(DGSM) XMY(DUZ)="" K:'$D(XMY) DGSM D ^XMD:$D(XMY)
58 ;
Note: See TracBrowser for help on using the repository browser.