IS00030A ;Compiled from script 'Generated: HL IHS IZV04 QBP OUT-O' on AUG 03, 2015
;Part 2
;Copyright 2015 SAIC
EN D:'INVS MC^INHS
K LINE S LINE="",CP=0 S L1="QPD" S:$TR(L1,$G(SUBDELIM))="" L1="" D SETPIECE^INHU(.LINE,DELIM,1,L1,.CP) S L1=$G(@INV@("QPD1")) S:$TR(L1,$G(SUBDELIM))="" L1=""
D SETPIECE^INHU(.LINE,DELIM,2,L1,.CP) S L1=$G(@INV@("QPD2")) S:$TR(L1,$G(SUBDELIM))="" L1="" D SETPIECE^INHU(.LINE,DELIM,3,L1,.CP) S L1=$G(@INV@("QPD3"))
S:$TR(L1,$G(SUBDELIM))="" L1="" D SETPIECE^INHU(.LINE,DELIM,4,L1,.CP) S L1=$G(@INV@("QPD4")) S:$TR(L1,$G(SUBDELIM))="" L1="" D SETPIECE^INHU(.LINE,DELIM,5,L1,.CP)
S L1=$G(@INV@("QPD5")) S:$TR(L1,$G(SUBDELIM))="" L1="" D SETPIECE^INHU(.LINE,DELIM,6,L1,.CP) S L1=$G(@INV@("QPD6")) S:$TR(L1,$G(SUBDELIM))="" L1="" D SETPIECE^INHU(.LINE,DELIM,7,L1,.CP)
S L1=$G(@INV@("QPD7")) S:$TR(L1,$G(SUBDELIM))="" L1="" D SETPIECE^INHU(.LINE,DELIM,8,L1,.CP) S L1=$G(@INV@("QPD8.1"))
S D0=INDA S X="^" S L1=L1_X
S L1=L1_$G(@INV@("QPD8.2"))
S D0=INDA S X="^" S L1=L1_X
S L1=L1_$G(@INV@("QPD8.3"))
S D0=INDA S X="^" S L1=L1_X
S L1=L1_$G(@INV@("QPD8.4"))
S D0=INDA S X="^" S L1=L1_X
S L1=L1_$G(@INV@("QPD8.5")) S:$TR(L1,$G(SUBDELIM))="" L1="" D SETPIECE^INHU(.LINE,DELIM,9,L1,.CP)
S LCT=LCT+1,^UTILITY("INH",$J,LCT)=LINE I $D(LINE)>9 M ^UTILITY("INH",$J,LCT)=LINE
SET INSETID=0
D RCP^BYIMSEGS
;SET RCP1 = $E(INTERNAL("1"),1,1)
S D0=INDA S X="1",X=X S X=X,Y(1)=$G(X) S X=1,Y(2)=$G(X) S X=1,X=$E(Y(1),Y(2),X)
S @INV@("RCP1")=X K DXS,D0
;SET RCP2 = INSGX\^INTHL7F(17019,5)\\10\"OUTPUT TRANSFORM"
S D0=INDA S X="OUTPUT TRANSFORM"
S X1="^INTHL7F(17019,5)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,10)
S @INV@("RCP2")=X K DXS,D0
;SET RCP3 = INSGX\^INTHL7F(17020,5)\\60\"OUTPUT TRANSFORM"
S D0=INDA S X="OUTPUT TRANSFORM"
S X1="^INTHL7F(17020,5)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,60)
S @INV@("RCP3")=X K DXS,D0
D:'INVS MC^INHS
K LINE S LINE="",CP=0 S L1="RCP" S:$TR(L1,$G(SUBDELIM))="" L1="" D SETPIECE^INHU(.LINE,DELIM,1,L1,.CP) S L1=$G(@INV@("RCP1")) S:$TR(L1,$G(SUBDELIM))="" L1=""
D SETPIECE^INHU(.LINE,DELIM,2,L1,.CP) S L1=$G(@INV@("RCP2")) S:$TR(L1,$G(SUBDELIM))="" L1="" D SETPIECE^INHU(.LINE,DELIM,3,L1,.CP) S L1=$G(@INV@("RCP3"))
S:$TR(L1,$G(SUBDELIM))="" L1="" D SETPIECE^INHU(.LINE,DELIM,4,L1,.CP)
S LCT=LCT+1,^UTILITY("INH",$J,LCT)=LINE I $D(LINE)>9 M ^UTILITY("INH",$J,LCT)=LINE
D:'INVS MC^INHS
;Entering END section.
I $G(INSTERR) Q $S($G(INREQERR)>INSTERR:INREQERR,1:INSTERR)
S UIF=$$NEWO^INHD(INDEST,"^UTILITY(""INH"",$J)",+$P($G(^INRHT(INTT,0)),U,12),INTT,MESSID,$G(INQUE),$G(INORDUZ),$G(INORDIV),.INUIF6,.INUIF7,$G(INA("INMIDGEN")))
I UIF<0 D ERROR^INHS("UIF creation failed",2) Q 2
Q 0
IS00030A ;Compiled from script 'Generated: HL IHS IZV04 QBP OUT-O' on AUG 03, 2015
+1 ;Part 2
+2 ;Copyright 2015 SAIC
EN IF 'INVS
DO MC^INHS
+1 KILL LINE
SET LINE=""
SET CP=0
SET L1="QPD"
IF $TRANSLATE(L1,$GET(SUBDELIM))=""
SET L1=""
DO SETPIECE^INHU(.LINE,DELIM,1,L1,.CP)
SET L1=$GET(@INV@("QPD1"))
IF $TRANSLATE(L1,$GET(SUBDELIM))=""
SET L1=""
+2 DO SETPIECE^INHU(.LINE,DELIM,2,L1,.CP)
SET L1=$GET(@INV@("QPD2"))
IF $TRANSLATE(L1,$GET(SUBDELIM))=""
SET L1=""
DO SETPIECE^INHU(.LINE,DELIM,3,L1,.CP)
SET L1=$GET(@INV@("QPD3"))
+3 IF $TRANSLATE(L1,$GET(SUBDELIM))=""
SET L1=""
DO SETPIECE^INHU(.LINE,DELIM,4,L1,.CP)
SET L1=$GET(@INV@("QPD4"))
IF $TRANSLATE(L1,$GET(SUBDELIM))=""
SET L1=""
DO SETPIECE^INHU(.LINE,DELIM,5,L1,.CP)
+4 SET L1=$GET(@INV@("QPD5"))
IF $TRANSLATE(L1,$GET(SUBDELIM))=""
SET L1=""
DO SETPIECE^INHU(.LINE,DELIM,6,L1,.CP)
SET L1=$GET(@INV@("QPD6"))
IF $TRANSLATE(L1,$GET(SUBDELIM))=""
SET L1=""
DO SETPIECE^INHU(.LINE,DELIM,7,L1,.CP)
+5 SET L1=$GET(@INV@("QPD7"))
IF $TRANSLATE(L1,$GET(SUBDELIM))=""
SET L1=""
DO SETPIECE^INHU(.LINE,DELIM,8,L1,.CP)
SET L1=$GET(@INV@("QPD8.1"))
+6 SET D0=INDA
SET X="^"
SET L1=L1_X
+7 SET L1=L1_$GET(@INV@("QPD8.2"))
+8 SET D0=INDA
SET X="^"
SET L1=L1_X
+9 SET L1=L1_$GET(@INV@("QPD8.3"))
+10 SET D0=INDA
SET X="^"
SET L1=L1_X
+11 SET L1=L1_$GET(@INV@("QPD8.4"))
+12 SET D0=INDA
SET X="^"
SET L1=L1_X
+13 SET L1=L1_$GET(@INV@("QPD8.5"))
IF $TRANSLATE(L1,$GET(SUBDELIM))=""
SET L1=""
DO SETPIECE^INHU(.LINE,DELIM,9,L1,.CP)
+14 SET LCT=LCT+1
SET ^UTILITY("INH",$JOB,LCT)=LINE
IF $DATA(LINE)>9
MERGE ^UTILITY("INH",$JOB,LCT)=LINE
+15 SET INSETID=0
+16 DO RCP^BYIMSEGS
+17 ;SET RCP1 = $E(INTERNAL("1"),1,1)
+18 SET D0=INDA
SET X="1"
SET X=X
SET X=X
SET Y(1)=$GET(X)
SET X=1
SET Y(2)=$GET(X)
SET X=1
SET X=$EXTRACT(Y(1),Y(2),X)
+19 SET @INV@("RCP1")=X
KILL DXS,D0
+20 ;SET RCP2 = INSGX\^INTHL7F(17019,5)\\10\"OUTPUT TRANSFORM"
+21 SET D0=INDA
SET X="OUTPUT TRANSFORM"
+22 SET X1="^INTHL7F(17019,5)"
IF $LENGTH($GET(@X1))
XECUTE $GET(@X1)
SET X=$EXTRACT(X,1,10)
+23 SET @INV@("RCP2")=X
KILL DXS,D0
+24 ;SET RCP3 = INSGX\^INTHL7F(17020,5)\\60\"OUTPUT TRANSFORM"
+25 SET D0=INDA
SET X="OUTPUT TRANSFORM"
+26 SET X1="^INTHL7F(17020,5)"
IF $LENGTH($GET(@X1))
XECUTE $GET(@X1)
SET X=$EXTRACT(X,1,60)
+27 SET @INV@("RCP3")=X
KILL DXS,D0
+28 IF 'INVS
DO MC^INHS
+29 KILL LINE
SET LINE=""
SET CP=0
SET L1="RCP"
IF $TRANSLATE(L1,$GET(SUBDELIM))=""
SET L1=""
DO SETPIECE^INHU(.LINE,DELIM,1,L1,.CP)
SET L1=$GET(@INV@("RCP1"))
IF $TRANSLATE(L1,$GET(SUBDELIM))=""
SET L1=""
+30 DO SETPIECE^INHU(.LINE,DELIM,2,L1,.CP)
SET L1=$GET(@INV@("RCP2"))
IF $TRANSLATE(L1,$GET(SUBDELIM))=""
SET L1=""
DO SETPIECE^INHU(.LINE,DELIM,3,L1,.CP)
SET L1=$GET(@INV@("RCP3"))
+31 IF $TRANSLATE(L1,$GET(SUBDELIM))=""
SET L1=""
DO SETPIECE^INHU(.LINE,DELIM,4,L1,.CP)
+32 SET LCT=LCT+1
SET ^UTILITY("INH",$JOB,LCT)=LINE
IF $DATA(LINE)>9
MERGE ^UTILITY("INH",$JOB,LCT)=LINE
+33 IF 'INVS
DO MC^INHS
+34 ;Entering END section.
+35 IF $GET(INSTERR)
QUIT $SELECT($GET(INREQERR)>INSTERR:INREQERR,1:INSTERR)
+36 SET UIF=$$NEWO^INHD(INDEST,"^UTILITY(""INH"",$J)",+$PIECE($GET(^INRHT(INTT,0)),U,12),INTT,MESSID,$GET(INQUE),$GET(INORDUZ),$GET(INORDIV),.INUIF6,.INUIF7,$GET(INA("INMIDGEN")))
+37 IF UIF<0
DO ERROR^INHS("UIF creation failed",2)
QUIT 2
+38 QUIT 0