IS00002B ;Compiled from script 'Generated: HL IHS LOINC R01-O' on DEC 03, 2002
;Part 3
;Copyright 2002 SAIC
EN S X1="^INTHL7FT(1,3)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,250)
S @INV@("OBR4")=X K DXS,D0
;SET OBR7 = INSGX\^INTHL7FT(6,3)\\26\#1201
S D0=INDA S Y(1)=$S($D(^AUPNVLAB(D0,12)):^(12),1:"") S X=$P(Y(1),U,1)
S X1="^INTHL7FT(6,3)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,26)
S @INV@("OBR7")=X K DXS,D0
;SET OBR9 = INSGX\^INTHL7FT(1,3)\\250\#1114
S D0=INDA S Y(1)=$S($D(^AUPNVLAB(D0,11)):^(11),1:"") S X=$S('$D(^LAB(62,+$P(Y(1),U,14),0)):"",1:$P(^(0),U,1))
S X1="^INTHL7FT(1,3)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,250)
S @INV@("OBR9")=X K DXS,D0
;SET OBR15 = INSGX\^INTHL7FT(1,3)\\250\#1103
S D0=INDA S Y(1)=$S($D(^AUPNVLAB(D0,11)):^(11),1:"") S X=$S('$D(^LAB(61,+$P(Y(1),U,3),0)):"",1:$P(^(0),U,1))
S X1="^INTHL7FT(1,3)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,250)
S @INV@("OBR15")=X K DXS,D0
;SET OBR22 = INSGX\^INTHL7F(15561,5)\\26\"OUTPUT TRANSFORM"
S D0=INDA S X="OUTPUT TRANSFORM"
S X1="^INTHL7F(15561,5)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,26)
S @INV@("OBR22")=X K DXS,D0
;SET OBR25 = INSGX\^INTHL7F(15562,5)\\1\"OUTPUT TRANSFORM"
S D0=INDA S X="OUTPUT TRANSFORM"
S X1="^INTHL7F(15562,5)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,1)
S @INV@("OBR25")=X K DXS,D0
D:'INVS MC^INHS
K LINE S LINE="",CP=0 S L1="OBR" S:$TR(L1,$G(SUBDELIM))="" L1="" D SETPIECE^INHU(.LINE,DELIM,1,L1,.CP) S L1=$G(@INV@("OBR1")) S:$TR(L1,$G(SUBDELIM))="" L1=""
D SETPIECE^INHU(.LINE,DELIM,2,L1,.CP) S L1=$G(@INV@("OBR2")) S:$TR(L1,$G(SUBDELIM))="" L1="" D SETPIECE^INHU(.LINE,DELIM,3,L1,.CP) S L1=$G(@INV@("OBR4"))
S:$TR(L1,$G(SUBDELIM))="" L1="" D SETPIECE^INHU(.LINE,DELIM,5,L1,.CP) S L1=$G(@INV@("OBR7")) S:$TR(L1,$G(SUBDELIM))="" L1="" D SETPIECE^INHU(.LINE,DELIM,8,L1,.CP)
S L1=$G(@INV@("OBR9")) S:$TR(L1,$G(SUBDELIM))="" L1="" D SETPIECE^INHU(.LINE,DELIM,10,L1,.CP) S L1=$G(@INV@("OBR15")) S:$TR(L1,$G(SUBDELIM))="" L1="" D SETPIECE^INHU(.LINE,DELIM,16,L1,.CP)
S L1=$G(@INV@("OBR22")) S:$TR(L1,$G(SUBDELIM))="" L1="" D SETPIECE^INHU(.LINE,DELIM,23,L1,.CP) S L1=$G(@INV@("OBR25")) S:$TR(L1,$G(SUBDELIM))="" L1=""
D SETPIECE^INHU(.LINE,DELIM,26,L1,.CP)
S LCT=LCT+1,^UTILITY("INH",$J,LCT)=LINE I $D(LINE)>9 M ^UTILITY("INH",$J,LCT)=LINE
Q
B1 S INDA=INDA0 K INDA0
SET INSETID=0
I '$D(INDA(9000010.09)) S INI=0 F S INI=$O(^AUPNVLAB("AC",INDA,INI)) Q:'INI S INDA(9000010.09,INI)=""
S INDA0=INDA,INI(1)=0 F S INI(1)=$O(INDA(9000010.09,INI(1))) Q:'INI(1) S INDA=$S(INDA(9000010.09,INI(1)):INDA(9000010.09,INI(1)),1:INI(1)) D
.Q:'$D(^AUPNVLAB(INDA,0))
.;SET OBX1 = INSGX\^INTHL7FT(11,3)\\3\"OBX"
.S D0=INDA S X="OBX"
.S X1="^INTHL7FT(11,3)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,3)
.S @INV@("OBX1")=X K DXS,D0
.;SET OBX2 = INSGX\^INTHL7F(15564,5)\\250\"OUTPUT TRANSFORM"
.S D0=INDA S X="OUTPUT TRANSFORM"
.S X1="^INTHL7F(15564,5)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,250)
.S @INV@("OBX2")=X K DXS,D0
.;SET OBX3 = INSGX\^INTHL7FT(1,3)\\250\@OBR4LAB
.S D0=INDA S X=$G(INA("OBR4LAB",INI(1)))
.S X1="^INTHL7FT(1,3)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,250)
.S @INV@("OBX3")=X K DXS,D0
.;SET OBX5 = INSGX\^INTHL7FT(1,3)\\250\#.04
.S D0=INDA S Y(1)=$S($D(^AUPNVLAB(D0,0)):^(0),1:"") S X=$P(Y(1),U,4)
.S X1="^INTHL7FT(1,3)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,250)
.S @INV@("OBX5")=X K DXS,D0
.;SET OBX6 = INSGX\^INTHL7FT(1,3)\\250\#1101
.S D0=INDA S Y(1)=$S($D(^AUPNVLAB(D0,11)):^(11),1:"") S X=$P(Y(1),U,1)
.S X1="^INTHL7FT(1,3)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,250)
.S @INV@("OBX6")=X K DXS,D0
.;SET OBX7 = INSGX\^INTHL7FT(1,3)\\250\@OBX7LAB
.S D0=INDA S X=$G(INA("OBX7LAB",INI(1)))
.S X1="^INTHL7FT(1,3)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,250)
.S @INV@("OBX7")=X K DXS,D0
.;SET OBX8 = INSGX\^INTHL7FT(1,3)\\250\#.05
.S D0=INDA S Y(1)=$S($D(^AUPNVLAB(D0,0)):^(0),1:"") S X=$P(Y(1),U,5)
.S X1="^INTHL7FT(1,3)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,250)
.S @INV@("OBX8")=X K DXS,D0
.;SET OBX11 = INSGX\^INTHL7F(15569,5)\\1\"OUTPUT TRANSFORM"
.S D0=INDA S X="OUTPUT TRANSFORM"
.S X1="^INTHL7F(15569,5)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,1)
.S @INV@("OBX11")=X K DXS,D0
.D:'INVS MC^INHS
.K LINE S LINE="",CP=0 S L1="OBX" S:$TR(L1,$G(SUBDELIM))="" L1="" D SETPIECE^INHU(.LINE,DELIM,1,L1,.CP) S L1=$G(@INV@("OBX1")) S:$TR(L1,$G(SUBDELIM))="" L1=""
.D SETPIECE^INHU(.LINE,DELIM,2,L1,.CP) S L1=$G(@INV@("OBX2")) S:$TR(L1,$G(SUBDELIM))="" L1="" D SETPIECE^INHU(.LINE,DELIM,3,L1,.CP) S L1=$G(@INV@("OBX3"))
9 .D EN^IS00002C
G C1^IS00002C
IS00002B ;Compiled from script 'Generated: HL IHS LOINC R01-O' on DEC 03, 2002
+1 ;Part 3
+2 ;Copyright 2002 SAIC
EN SET X1="^INTHL7FT(1,3)"
IF $LENGTH($GET(@X1))
XECUTE $GET(@X1)
SET X=$EXTRACT(X,1,250)
+1 SET @INV@("OBR4")=X
KILL DXS,D0
+2 ;SET OBR7 = INSGX\^INTHL7FT(6,3)\\26\#1201
+3 SET D0=INDA
SET Y(1)=$SELECT($DATA(^AUPNVLAB(D0,12)):^(12),1:"")
SET X=$PIECE(Y(1),U,1)
+4 SET X1="^INTHL7FT(6,3)"
IF $LENGTH($GET(@X1))
XECUTE $GET(@X1)
SET X=$EXTRACT(X,1,26)
+5 SET @INV@("OBR7")=X
KILL DXS,D0
+6 ;SET OBR9 = INSGX\^INTHL7FT(1,3)\\250\#1114
+7 SET D0=INDA
SET Y(1)=$SELECT($DATA(^AUPNVLAB(D0,11)):^(11),1:"")
SET X=$SELECT('$DATA(^LAB(62,+$PIECE(Y(1),U,14),0)):"",1:$PIECE(^(0),U,1))
+8 SET X1="^INTHL7FT(1,3)"
IF $LENGTH($GET(@X1))
XECUTE $GET(@X1)
SET X=$EXTRACT(X,1,250)
+9 SET @INV@("OBR9")=X
KILL DXS,D0
+10 ;SET OBR15 = INSGX\^INTHL7FT(1,3)\\250\#1103
+11 SET D0=INDA
SET Y(1)=$SELECT($DATA(^AUPNVLAB(D0,11)):^(11),1:"")
SET X=$SELECT('$DATA(^LAB(61,+$PIECE(Y(1),U,3),0)):"",1:$PIECE(^(0),U,1))
+12 SET X1="^INTHL7FT(1,3)"
IF $LENGTH($GET(@X1))
XECUTE $GET(@X1)
SET X=$EXTRACT(X,1,250)
+13 SET @INV@("OBR15")=X
KILL DXS,D0
+14 ;SET OBR22 = INSGX\^INTHL7F(15561,5)\\26\"OUTPUT TRANSFORM"
+15 SET D0=INDA
SET X="OUTPUT TRANSFORM"
+16 SET X1="^INTHL7F(15561,5)"
IF $LENGTH($GET(@X1))
XECUTE $GET(@X1)
SET X=$EXTRACT(X,1,26)
+17 SET @INV@("OBR22")=X
KILL DXS,D0
+18 ;SET OBR25 = INSGX\^INTHL7F(15562,5)\\1\"OUTPUT TRANSFORM"
+19 SET D0=INDA
SET X="OUTPUT TRANSFORM"
+20 SET X1="^INTHL7F(15562,5)"
IF $LENGTH($GET(@X1))
XECUTE $GET(@X1)
SET X=$EXTRACT(X,1,1)
+21 SET @INV@("OBR25")=X
KILL DXS,D0
+22 IF 'INVS
DO MC^INHS
+23 KILL LINE
SET LINE=""
SET CP=0
SET L1="OBR"
IF $TRANSLATE(L1,$GET(SUBDELIM))=""
SET L1=""
DO SETPIECE^INHU(.LINE,DELIM,1,L1,.CP)
SET L1=$GET(@INV@("OBR1"))
IF $TRANSLATE(L1,$GET(SUBDELIM))=""
SET L1=""
+24 DO SETPIECE^INHU(.LINE,DELIM,2,L1,.CP)
SET L1=$GET(@INV@("OBR2"))
IF $TRANSLATE(L1,$GET(SUBDELIM))=""
SET L1=""
DO SETPIECE^INHU(.LINE,DELIM,3,L1,.CP)
SET L1=$GET(@INV@("OBR4"))
+25 IF $TRANSLATE(L1,$GET(SUBDELIM))=""
SET L1=""
DO SETPIECE^INHU(.LINE,DELIM,5,L1,.CP)
SET L1=$GET(@INV@("OBR7"))
IF $TRANSLATE(L1,$GET(SUBDELIM))=""
SET L1=""
DO SETPIECE^INHU(.LINE,DELIM,8,L1,.CP)
+26 SET L1=$GET(@INV@("OBR9"))
IF $TRANSLATE(L1,$GET(SUBDELIM))=""
SET L1=""
DO SETPIECE^INHU(.LINE,DELIM,10,L1,.CP)
SET L1=$GET(@INV@("OBR15"))
IF $TRANSLATE(L1,$GET(SUBDELIM))=""
SET L1=""
DO SETPIECE^INHU(.LINE,DELIM,16,L1,.CP)
+27 SET L1=$GET(@INV@("OBR22"))
IF $TRANSLATE(L1,$GET(SUBDELIM))=""
SET L1=""
DO SETPIECE^INHU(.LINE,DELIM,23,L1,.CP)
SET L1=$GET(@INV@("OBR25"))
IF $TRANSLATE(L1,$GET(SUBDELIM))=""
SET L1=""
+28 DO SETPIECE^INHU(.LINE,DELIM,26,L1,.CP)
+29 SET LCT=LCT+1
SET ^UTILITY("INH",$JOB,LCT)=LINE
IF $DATA(LINE)>9
MERGE ^UTILITY("INH",$JOB,LCT)=LINE
+30 QUIT
B1 SET INDA=INDA0
KILL INDA0
+1 SET INSETID=0
+2 IF '$DATA(INDA(9000010.09))
SET INI=0
FOR
SET INI=$ORDER(^AUPNVLAB("AC",INDA,INI))
IF 'INI
QUIT
SET INDA(9000010.09,INI)=""
+3 SET INDA0=INDA
SET INI(1)=0
FOR
SET INI(1)=$ORDER(INDA(9000010.09,INI(1)))
IF 'INI(1)
QUIT
SET INDA=$SELECT(INDA(9000010.09,INI(1)):INDA(9000010.09,INI(1)),1:INI(1))
Begin DoDot:1
+4 IF '$DATA(^AUPNVLAB(INDA,0))
QUIT
+5 ;SET OBX1 = INSGX\^INTHL7FT(11,3)\\3\"OBX"
+6 SET D0=INDA
SET X="OBX"
+7 SET X1="^INTHL7FT(11,3)"
IF $LENGTH($GET(@X1))
XECUTE $GET(@X1)
SET X=$EXTRACT(X,1,3)
+8 SET @INV@("OBX1")=X
KILL DXS,D0
+9 ;SET OBX2 = INSGX\^INTHL7F(15564,5)\\250\"OUTPUT TRANSFORM"
+10 SET D0=INDA
SET X="OUTPUT TRANSFORM"
+11 SET X1="^INTHL7F(15564,5)"
IF $LENGTH($GET(@X1))
XECUTE $GET(@X1)
SET X=$EXTRACT(X,1,250)
+12 SET @INV@("OBX2")=X
KILL DXS,D0
+13 ;SET OBX3 = INSGX\^INTHL7FT(1,3)\\250\@OBR4LAB
+14 SET D0=INDA
SET X=$GET(INA("OBR4LAB",INI(1)))
+15 SET X1="^INTHL7FT(1,3)"
IF $LENGTH($GET(@X1))
XECUTE $GET(@X1)
SET X=$EXTRACT(X,1,250)
+16 SET @INV@("OBX3")=X
KILL DXS,D0
+17 ;SET OBX5 = INSGX\^INTHL7FT(1,3)\\250\#.04
+18 SET D0=INDA
SET Y(1)=$SELECT($DATA(^AUPNVLAB(D0,0)):^(0),1:"")
SET X=$PIECE(Y(1),U,4)
+19 SET X1="^INTHL7FT(1,3)"
IF $LENGTH($GET(@X1))
XECUTE $GET(@X1)
SET X=$EXTRACT(X,1,250)
+20 SET @INV@("OBX5")=X
KILL DXS,D0
+21 ;SET OBX6 = INSGX\^INTHL7FT(1,3)\\250\#1101
+22 SET D0=INDA
SET Y(1)=$SELECT($DATA(^AUPNVLAB(D0,11)):^(11),1:"")
SET X=$PIECE(Y(1),U,1)
+23 SET X1="^INTHL7FT(1,3)"
IF $LENGTH($GET(@X1))
XECUTE $GET(@X1)
SET X=$EXTRACT(X,1,250)
+24 SET @INV@("OBX6")=X
KILL DXS,D0
+25 ;SET OBX7 = INSGX\^INTHL7FT(1,3)\\250\@OBX7LAB
+26 SET D0=INDA
SET X=$GET(INA("OBX7LAB",INI(1)))
+27 SET X1="^INTHL7FT(1,3)"
IF $LENGTH($GET(@X1))
XECUTE $GET(@X1)
SET X=$EXTRACT(X,1,250)
+28 SET @INV@("OBX7")=X
KILL DXS,D0
+29 ;SET OBX8 = INSGX\^INTHL7FT(1,3)\\250\#.05
+30 SET D0=INDA
SET Y(1)=$SELECT($DATA(^AUPNVLAB(D0,0)):^(0),1:"")
SET X=$PIECE(Y(1),U,5)
+31 SET X1="^INTHL7FT(1,3)"
IF $LENGTH($GET(@X1))
XECUTE $GET(@X1)
SET X=$EXTRACT(X,1,250)
+32 SET @INV@("OBX8")=X
KILL DXS,D0
+33 ;SET OBX11 = INSGX\^INTHL7F(15569,5)\\1\"OUTPUT TRANSFORM"
+34 SET D0=INDA
SET X="OUTPUT TRANSFORM"
+35 SET X1="^INTHL7F(15569,5)"
IF $LENGTH($GET(@X1))
XECUTE $GET(@X1)
SET X=$EXTRACT(X,1,1)
+36 SET @INV@("OBX11")=X
KILL DXS,D0
+37 IF 'INVS
DO MC^INHS
+38 KILL LINE
SET LINE=""
SET CP=0
SET L1="OBX"
IF $TRANSLATE(L1,$GET(SUBDELIM))=""
SET L1=""
DO SETPIECE^INHU(.LINE,DELIM,1,L1,.CP)
SET L1=$GET(@INV@("OBX1"))
IF $TRANSLATE(L1,$GET(SUBDELIM))=""
SET L1=""
+39 DO SETPIECE^INHU(.LINE,DELIM,2,L1,.CP)
SET L1=$GET(@INV@("OBX2"))
IF $TRANSLATE(L1,$GET(SUBDELIM))=""
SET L1=""
DO SETPIECE^INHU(.LINE,DELIM,3,L1,.CP)
SET L1=$GET(@INV@("OBX3"))
9 DO EN^IS00002C
End DoDot:1
+1 GOTO C1^IS00002C