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

IBARXEC4.m

Go to the documentation of this file.
  1. IBARXEC4 ;ALB/AAS - RX COPAY EXEMPTION CONVERSION REPORT BUILD ; 14-JAN-93
  1. ;;2.0; INTEGRATED BILLING ;**78**; 21-MAR-94
  1. ;;Per VHA Directive 10-93-142, this routine should not be modified.
  1. ;
  1. % ;
  1. BUILD ; -- Build report
  1. ;
  1. N IBERR S (IBERR,IBOK,IBN)=0
  1. F S IBN=$O(^IB("AC",11,IBN)) Q:'IBN D CHK,SET:IBOK
  1. D:IBERR>0 ERRMSG Q
  1. ;
  1. CHK ; -- is entry in date range
  1. S IBOK=0
  1. S X=$G(^IB(IBN,0)),X1=$G(^IB(IBN,1))
  1. I X=""!(X1="") S IBERR=IBERR+1,IBERR(IBN)="" Q
  1. I (IBBDT-.00001)<$P(X1,"^",2),(IBEDT+.9)>$P(X1,"^",2) S IBOK=1
  1. CHKQ Q
  1. ;
  1. SET ; -- set entry in ^tmp
  1. S DFN=$P(X,"^",2)
  1. S IBP=$$PT^IBEFUNC(DFN) ; name^bid^pid
  1. S ^TMP("IBCONV",$J,$P(IBP,"^"),DFN,IBN)=IBP
  1. Q
  1. ;
  1. ERRMSG ; -- transmits error message
  1. N XMDUZ,XMSUB,XMTEXT,XMY,X0,X1,X2 K ^TMP("IBERR",$J)
  1. S ^TMP("IBERR",$J,1)="The Print Charges Canceled Due to Income Exemption option ran into"
  1. S ^TMP("IBERR",$J,2)="a possible data corruption problem in the INTEGRATED BILLING ACTION"
  1. S ^TMP("IBERR",$J,3)="file during its run. The option has encountered "_IBERR_" '^IB(""AC"",11' cross"
  1. S ^TMP("IBERR",$J,4)="reference entr"_$S(IBERR>1:"ies",1:"y")_" for which there "_$S(IBERR>1:"were",1:"was")_" no corresponding 0 or 1 node"_$S(IBERR>1:"s",1:"")_" in the"
  1. S ^TMP("IBERR",$J,5)="file's global. The file internal entry number"_$S(IBERR>1:"s",1:"")_" (IEN"_$S(IBERR>1:"s",1:"")_") for the missing"
  1. S ^TMP("IBERR",$J,6)="node"_$S(IBERR>1:"s are",1:" is")_" the following:",^TMP("IBERR",$J,7)="",^TMP("IBERR",$J,8)=" "
  1. S (X0,X1)=0,X2=8 F S X0=$O(IBERR(X0)) Q:X0="" D
  1. .S ^TMP("IBERR",$J,X2)=^TMP("IBERR",$J,X2)_$J(X0,7)_" ",X1=X1+1
  1. .I X1=6,+$O(IBERR(X0))>0 S X1=0,X2=X2+1,^TMP("IBERR",$J,X2)=" "
  1. S ^TMP("IBERR",$J,(X2+1))="",^TMP("IBERR",$J,(X2+2))="Please notify your IRM service of this so that they can check this"
  1. S ^TMP("IBERR",$J,(X2+3))="file and make the appropriate fixes. The report will still print out,"
  1. S ^TMP("IBERR",$J,(X2+4))="but it may not have all the data you requested. Thank you."
  1. S XMSUB="**WARNING** POSSIBLE FILE ERROR",XMTEXT="^TMP(""IBERR"",$J,"
  1. S XMDUZ=.5,XMY("G.IB ERROR")="" D ^XMD K ^TMP("IBERR",$J) Q