IBINI0A9 ; ; 21-MAR-1994
;;Version 2.0 ; INTEGRATED BILLING ;; 21-MAR-94
Q:'DIFQ(399) F I=1:2 S X=$T(Q+I) Q:X="" S Y=$E($T(Q+I+1),4,999),X=$E(X,4,999) S:$A(Y)=126 I=I+1,Y=$E(Y,2,999)_$E($T(Q+I+1),5,99) S:$A(Y)=61 Y=$E(Y,2,999) X NO E S @X=Y
Q Q
;;^DD(399,59,12.1)
;;=S DIC("S")="I $P(^(0),""^"",1)?1A.N"
;;^DD(399,59,21,0)
;;=^^3^3^2911104^^
;;^DD(399,59,21,1,0)
;;=This is a HCFA outpatient procedure code.
;;^DD(399,59,21,2,0)
;;=
;;^DD(399,59,21,3,0)
;;=This field has been marked for deletion on 11/4/91.
;;^DD(399,59,"DT")
;;=2920122
;;^DD(399,60,0)
;;=OUTPATIENT DIAGNOSIS^FX^^C;10^K:$L(X)>45!($L(X)<1)!'(X?1U.ANP) X
;;^DD(399,60,3)
;;=Answer must be 1-45 characters in length.
;;^DD(399,60,5,1,0)
;;=399^64^1
;;^DD(399,60,9)
;;=^
;;^DD(399,60,21,0)
;;=^^1^1^2900525^^^^
;;^DD(399,60,21,1,0)
;;=The outpatient diagnosis is selectable from the ICD DIAGNOSIS file.
;;^DD(399,60,"DT")
;;=2900613
;;^DD(399,61,0)
;;=*PROCDEDURE DATE (1)^RDX^^C;11^S %DT="EX" D ^%DT S X=Y I $D(X) D DTMES^IBCU7
;;^DD(399,61,.1)
;;=PROCEDURE DATE (1)
;;^DD(399,61,3)
;;=TYPE A DATE ON OR BEFORE TODAY
;;^DD(399,61,21,0)
;;=^^4^4^2920615^^^^
;;^DD(399,61,21,1,0)
;;=This is the date on which the first procedure associated with this
;;^DD(399,61,21,2,0)
;;=billing episode occurred.
;;^DD(399,61,21,3,0)
;;=
;;^DD(399,61,21,4,0)
;;=This field has been marked for deletion on 11/4/91.
;;^DD(399,61,"DT")
;;=2911104
;;^DD(399,62,0)
;;=*PROCEDURE DATE (2)^RDX^^C;12^S %DT="EX" D ^%DT S X=Y I $D(X) D DTMES^IBCU7
;;^DD(399,62,.1)
;;=PROCEDURE DATE (2)
;;^DD(399,62,3)
;;=
;;^DD(399,62,21,0)
;;=^^4^4^2911104^^
;;^DD(399,62,21,1,0)
;;=This is the date on which the second procedure associated with
;;^DD(399,62,21,2,0)
;;=this billing episode occurred.
;;^DD(399,62,21,3,0)
;;=
;;^DD(399,62,21,4,0)
;;=This field has been marked for deletion on 11/4/91.
;;^DD(399,62,"DT")
;;=2911104
;;^DD(399,63,0)
;;=*PROCEDURE DATE (3)^RDX^^C;13^S %DT="EX" D ^%DT S X=Y I $D(X) D DTMES^IBCU7
;;^DD(399,63,.1)
;;=PROCEDURE DATE (3)
;;^DD(399,63,3)
;;=TYPE A DATE ON OR BEFORE TODAY
;;^DD(399,63,21,0)
;;=^^4^4^2911104^^
;;^DD(399,63,21,1,0)
;;=This is the date on which the third procedure associated with this
;;^DD(399,63,21,2,0)
;;=billing episode occurred.
;;^DD(399,63,21,3,0)
;;=
;;^DD(399,63,21,4,0)
;;=This field has been marked for deletion on 11/4/91.
;;^DD(399,63,"DT")
;;=2911104
;;^DD(399,64,0)
;;=*ICD DIAGNOSIS CODE (1)^RP80'^ICD9(^C;14^Q
;;^DD(399,64,.1)
;;=ICD DIAGNOSIS CODE (1)
;;^DD(399,64,1,0)
;;=^.1
;;^DD(399,64,1,1,0)
;;=^^TRIGGER^399^60
;;^DD(399,64,1,1,1)
;;=K DIV S DIV=X,D0=DA,DIV(0)=D0 S Y(0)=X I $P(^DGCR(399,DA,0),"^",5)>2 I X S X=DIV S Y(1)=$S($D(^DGCR(399,D0,"C")):^("C"),1:"") S X=$P(Y(1),U,10),X=X S DIU=X K Y S X=DIV S X=$P(^ICD9(+X,0),"^",3) X ^DD(399,64,1,1,1.4)
;;^DD(399,64,1,1,1.4)
;;=S DIH=$S($D(^DGCR(399,DIV(0),"C")):^("C"),1:""),DIV=X S $P(^("C"),U,10)=DIV,DIH=399,DIG=60 D ^DICR:$N(^DD(DIH,DIG,1,0))>0
;;^DD(399,64,1,1,2)
;;=K DIV S DIV=X,D0=DA,DIV(0)=D0 S Y(1)=$S($D(^DGCR(399,D0,"C")):^("C"),1:"") S X=$P(Y(1),U,10),X=X S DIU=X K Y S X="" X ^DD(399,64,1,1,2.4)
;;^DD(399,64,1,1,2.4)
;;=S DIH=$S($D(^DGCR(399,DIV(0),"C")):^("C"),1:""),DIV=X S $P(^("C"),U,10)=DIV,DIH=399,DIG=60 D ^DICR:$N(^DD(DIH,DIG,1,0))>0
;;^DD(399,64,1,1,"%D",0)
;;=^^1^1^2920211^
;;^DD(399,64,1,1,"%D",1,0)
;;=Sets the Outpatient Diagnosis to the ICD DIAGNOSIS CODE (1).
;;^DD(399,64,1,1,"CREATE CONDITION")
;;=I $P(^DGCR(399,DA,0),"^",5)>2
;;^DD(399,64,1,1,"CREATE VALUE")
;;=S X=$P(^ICD9(+X,0),"^",3)
;;^DD(399,64,1,1,"DELETE VALUE")
;;=@
;;^DD(399,64,1,1,"DT")
;;=2920211
;;^DD(399,64,1,1,"FIELD")
;;=#60
;;^DD(399,64,3)
;;=Enter the ICD diagnosis code which pertains to this billing episode.
;;^DD(399,64,21,0)
;;=^^1^1^2931117^^^
IBINI0A9 ; ; 21-MAR-1994
+1 ;;Version 2.0 ; INTEGRATED BILLING ;; 21-MAR-94
+2 IF 'DIFQ(399)
QUIT
FOR I=1:2
SET X=$TEXT(Q+I)
IF X=""
QUIT
SET Y=$EXTRACT($TEXT(Q+I+1),4,999)
SET X=$EXTRACT(X,4,999)
IF $ASCII(Y)=126
SET I=I+1
SET Y=$EXTRACT(Y,2,999)_$EXTRACT($TEXT(Q+I+1),5,99)
IF $ASCII(Y)=61
SET Y=$EXTRACT(Y,2,999)
XECUTE NO
IF '$TEST
SET @X=Y
Q QUIT
+1 ;;^DD(399,59,12.1)
+2 ;;=S DIC("S")="I $P(^(0),""^"",1)?1A.N"
+3 ;;^DD(399,59,21,0)
+4 ;;=^^3^3^2911104^^
+5 ;;^DD(399,59,21,1,0)
+6 ;;=This is a HCFA outpatient procedure code.
+7 ;;^DD(399,59,21,2,0)
+8 ;;=
+9 ;;^DD(399,59,21,3,0)
+10 ;;=This field has been marked for deletion on 11/4/91.
+11 ;;^DD(399,59,"DT")
+12 ;;=2920122
+13 ;;^DD(399,60,0)
+14 ;;=OUTPATIENT DIAGNOSIS^FX^^C;10^K:$L(X)>45!($L(X)<1)!'(X?1U.ANP) X
+15 ;;^DD(399,60,3)
+16 ;;=Answer must be 1-45 characters in length.
+17 ;;^DD(399,60,5,1,0)
+18 ;;=399^64^1
+19 ;;^DD(399,60,9)
+20 ;;=^
+21 ;;^DD(399,60,21,0)
+22 ;;=^^1^1^2900525^^^^
+23 ;;^DD(399,60,21,1,0)
+24 ;;=The outpatient diagnosis is selectable from the ICD DIAGNOSIS file.
+25 ;;^DD(399,60,"DT")
+26 ;;=2900613
+27 ;;^DD(399,61,0)
+28 ;;=*PROCDEDURE DATE (1)^RDX^^C;11^S %DT="EX" D ^%DT S X=Y I $D(X) D DTMES^IBCU7
+29 ;;^DD(399,61,.1)
+30 ;;=PROCEDURE DATE (1)
+31 ;;^DD(399,61,3)
+32 ;;=TYPE A DATE ON OR BEFORE TODAY
+33 ;;^DD(399,61,21,0)
+34 ;;=^^4^4^2920615^^^^
+35 ;;^DD(399,61,21,1,0)
+36 ;;=This is the date on which the first procedure associated with this
+37 ;;^DD(399,61,21,2,0)
+38 ;;=billing episode occurred.
+39 ;;^DD(399,61,21,3,0)
+40 ;;=
+41 ;;^DD(399,61,21,4,0)
+42 ;;=This field has been marked for deletion on 11/4/91.
+43 ;;^DD(399,61,"DT")
+44 ;;=2911104
+45 ;;^DD(399,62,0)
+46 ;;=*PROCEDURE DATE (2)^RDX^^C;12^S %DT="EX" D ^%DT S X=Y I $D(X) D DTMES^IBCU7
+47 ;;^DD(399,62,.1)
+48 ;;=PROCEDURE DATE (2)
+49 ;;^DD(399,62,3)
+50 ;;=
+51 ;;^DD(399,62,21,0)
+52 ;;=^^4^4^2911104^^
+53 ;;^DD(399,62,21,1,0)
+54 ;;=This is the date on which the second procedure associated with
+55 ;;^DD(399,62,21,2,0)
+56 ;;=this billing episode occurred.
+57 ;;^DD(399,62,21,3,0)
+58 ;;=
+59 ;;^DD(399,62,21,4,0)
+60 ;;=This field has been marked for deletion on 11/4/91.
+61 ;;^DD(399,62,"DT")
+62 ;;=2911104
+63 ;;^DD(399,63,0)
+64 ;;=*PROCEDURE DATE (3)^RDX^^C;13^S %DT="EX" D ^%DT S X=Y I $D(X) D DTMES^IBCU7
+65 ;;^DD(399,63,.1)
+66 ;;=PROCEDURE DATE (3)
+67 ;;^DD(399,63,3)
+68 ;;=TYPE A DATE ON OR BEFORE TODAY
+69 ;;^DD(399,63,21,0)
+70 ;;=^^4^4^2911104^^
+71 ;;^DD(399,63,21,1,0)
+72 ;;=This is the date on which the third procedure associated with this
+73 ;;^DD(399,63,21,2,0)
+74 ;;=billing episode occurred.
+75 ;;^DD(399,63,21,3,0)
+76 ;;=
+77 ;;^DD(399,63,21,4,0)
+78 ;;=This field has been marked for deletion on 11/4/91.
+79 ;;^DD(399,63,"DT")
+80 ;;=2911104
+81 ;;^DD(399,64,0)
+82 ;;=*ICD DIAGNOSIS CODE (1)^RP80'^ICD9(^C;14^Q
+83 ;;^DD(399,64,.1)
+84 ;;=ICD DIAGNOSIS CODE (1)
+85 ;;^DD(399,64,1,0)
+86 ;;=^.1
+87 ;;^DD(399,64,1,1,0)
+88 ;;=^^TRIGGER^399^60
+89 ;;^DD(399,64,1,1,1)
+90 ;;=K DIV S DIV=X,D0=DA,DIV(0)=D0 S Y(0)=X I $P(^DGCR(399,DA,0),"^",5)>2 I X S X=DIV S Y(1)=$S($D(^DGCR(399,D0,"C")):^("C"),1:"") S X=$P(Y(1),U,10),X=X S DIU=X K Y S X=DIV S X=$P(^ICD9(+X,0),"^",3) X ^DD(399,64,1,1,1.4)
+91 ;;^DD(399,64,1,1,1.4)
+92 ;;=S DIH=$S($D(^DGCR(399,DIV(0),"C")):^("C"),1:""),DIV=X S $P(^("C"),U,10)=DIV,DIH=399,DIG=60 D ^DICR:$N(^DD(DIH,DIG,1,0))>0
+93 ;;^DD(399,64,1,1,2)
+94 ;;=K DIV S DIV=X,D0=DA,DIV(0)=D0 S Y(1)=$S($D(^DGCR(399,D0,"C")):^("C"),1:"") S X=$P(Y(1),U,10),X=X S DIU=X K Y S X="" X ^DD(399,64,1,1,2.4)
+95 ;;^DD(399,64,1,1,2.4)
+96 ;;=S DIH=$S($D(^DGCR(399,DIV(0),"C")):^("C"),1:""),DIV=X S $P(^("C"),U,10)=DIV,DIH=399,DIG=60 D ^DICR:$N(^DD(DIH,DIG,1,0))>0
+97 ;;^DD(399,64,1,1,"%D",0)
+98 ;;=^^1^1^2920211^
+99 ;;^DD(399,64,1,1,"%D",1,0)
+100 ;;=Sets the Outpatient Diagnosis to the ICD DIAGNOSIS CODE (1).
+101 ;;^DD(399,64,1,1,"CREATE CONDITION")
+102 ;;=I $P(^DGCR(399,DA,0),"^",5)>2
+103 ;;^DD(399,64,1,1,"CREATE VALUE")
+104 ;;=S X=$P(^ICD9(+X,0),"^",3)
+105 ;;^DD(399,64,1,1,"DELETE VALUE")
+106 ;;=@
+107 ;;^DD(399,64,1,1,"DT")
+108 ;;=2920211
+109 ;;^DD(399,64,1,1,"FIELD")
+110 ;;=#60
+111 ;;^DD(399,64,3)
+112 ;;=Enter the ICD diagnosis code which pertains to this billing episode.
+113 ;;^DD(399,64,21,0)
+114 ;;=^^1^1^2931117^^^