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

IS00020A.m

Go to the documentation of this file.
IS00020A ;Compiled from script 'Generated: HL IHS LAB O01 SONORA QUEST-O' on AUG 14, 2006
 ;Part 2
 ;Copyright 2006 SAIC
EN SET INSETID=0
 ;SET ORC1 = INSGX\^INTHL7F(16938,5)\\2\"OUTPUT TRANSFORM"
 S D0=INDA S X="OUTPUT TRANSFORM"
 S X1="^INTHL7F(16938,5)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,2)
 S @INV@("ORC1")=X K DXS,D0
 ;SET ORC2 = INSGX\^INTHL7FT(1,3)\\250\@ORC2LABO
 S D0=INDA S X=$G(INA("ORC2LABO"))
 S X1="^INTHL7FT(1,3)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,250)
 S @INV@("ORC2")=X K DXS,D0
 ;SET ORC9 = INSGX\^INTHL7FT(6,3)\\14\@ORC11LABO
 S D0=INDA S X=$G(INA("ORC11LABO"))
 S X1="^INTHL7FT(6,3)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,14)
 S @INV@("ORC9")=X K DXS,D0
 ;SET ORC12 = INSGX\^INTHL7FT(1,3)\\250\@ORC12LABO
 S D0=INDA S X=$G(INA("ORC12LABO"))
 S X1="^INTHL7FT(1,3)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,250)
 S @INV@("ORC12")=X K DXS,D0
 D:'INVS MC^INHS
 K LINE S LINE="",CP=0 S L1="ORC" S:$TR(L1,$G(SUBDELIM))="" L1="" D SETPIECE^INHU(.LINE,DELIM,1,L1,.CP) S L1=$G(@INV@("ORC1")) S:$TR(L1,$G(SUBDELIM))="" L1=""
 D SETPIECE^INHU(.LINE,DELIM,2,L1,.CP) S L1=$G(@INV@("ORC2")) S:$TR(L1,$G(SUBDELIM))="" L1="" D SETPIECE^INHU(.LINE,DELIM,3,L1,.CP) S L1=$G(@INV@("ORC9"))
 S:$TR(L1,$G(SUBDELIM))="" L1="" D SETPIECE^INHU(.LINE,DELIM,10,L1,.CP) S L1=$G(@INV@("ORC12")) S:$TR(L1,$G(SUBDELIM))="" L1="" D SETPIECE^INHU(.LINE,DELIM,13,L1,.CP)
 S LCT=LCT+1,^UTILITY("INH",$J,LCT)=LINE I $D(LINE)>9 M ^UTILITY("INH",$J,LCT)=LINE
 SET INSETID=0
 ;SET OBR1 = INSGX\^INTHL7FT(11,3)\\4\"OBR"
 S D0=INDA S X="OBR"
 S X1="^INTHL7FT(11,3)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,4)
 S @INV@("OBR1")=X K DXS,D0
 ;SET OBR2 = INSGX\^INTHL7FT(1,3)\\250\@ORC2LABO
 S D0=INDA S X=$G(INA("ORC2LABO"))
 S X1="^INTHL7FT(1,3)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,250)
 S @INV@("OBR2")=X K DXS,D0
 ;SET OBR4 = INSGX\^INTHL7FT(1,3)\\250\@OBR4LABO
 S D0=INDA S X=$G(INA("OBR4LABO"))
 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)\\14\@OBR7LABO
 S D0=INDA S X=$G(INA("OBR7LABO"))
 S X1="^INTHL7FT(6,3)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,14)
 S @INV@("OBR7")=X K DXS,D0
 ;SET OBR11 = INSGX\^INTHL7FT(1,3)\\999\@OBR13LABO
 S D0=INDA S X=$G(INA("OBR13LABO"))
 S X1="^INTHL7FT(1,3)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,999)
 S @INV@("OBR11")=X K DXS,D0
 ;SET OBR16 = INSGX\^INTHL7FT(1,3)\\250\@ORC12LABO
 S D0=INDA S X=$G(INA("ORC12LABO"))
 S X1="^INTHL7FT(1,3)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,250)
 S @INV@("OBR16")=X K DXS,D0
 ;SET OBR22 = INSGX\^INTHL7FT(6,3)\\26\@OBR22LABO
 S D0=INDA S X=$G(INA("OBR22LABO"))
 S X1="^INTHL7FT(6,3)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,26)
 S @INV@("OBR22")=X K DXS,D0
 ;SET OBR27 = INSGX\^INTHL7FT(1,3)\\1\@OBR27LABO
 S D0=INDA S X=$G(INA("OBR27LABO"))
 S X1="^INTHL7FT(1,3)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,1)
 S @INV@("OBR27")=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@("OBR11")) S:$TR(L1,$G(SUBDELIM))="" L1="" D SETPIECE^INHU(.LINE,DELIM,12,L1,.CP) S L1=$G(@INV@("OBR16")) S:$TR(L1,$G(SUBDELIM))="" L1=""
 D SETPIECE^INHU(.LINE,DELIM,17,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@("OBR27"))
 S:$TR(L1,$G(SUBDELIM))="" L1="" D SETPIECE^INHU(.LINE,DELIM,28,L1,.CP)
 S LCT=LCT+1,^UTILITY("INH",$J,LCT)=LINE I $D(LINE)>9 M ^UTILITY("INH",$J,LCT)=LINE
 SET INSETID=0
 S INDA0=INDA,INI(1)=0  F  S INI(1)=$O(INDA("OBX",INI(1))) Q:'INI(1)  S INDA=$S(INDA("OBX",INI(1)):INDA("OBX",INI(1)),1:INI(1)) D
 .;SET OBX1 = INSGX\^INTHL7FT(11,3)\\4\"OBX"
 .S D0=INDA S X="OBX"
 .S X1="^INTHL7FT(11,3)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,4)
 .S @INV@("OBX1")=X K DXS,D0
 .;SET OBX2 = INSGX\^INTHL7FT(1,3)\\999\"ST"
 .S D0=INDA S X="ST"
 .S X1="^INTHL7FT(1,3)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,999)
 .S @INV@("OBX2")=X K DXS,D0
 .;SET OBX3 = INSGX\^INTHL7FT(1,3)\\60\@OBX3LABO
 .S D0=INDA S X=$G(INA("OBX3LABO",INI(1)))
 .S X1="^INTHL7FT(1,3)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,60)
 .S @INV@("OBX3")=X K DXS,D0
 .;SET OBX5 = INSGX\^INTHL7FT(1,3)\\999\@OBX5LABO
 .S D0=INDA S X=$G(INA("OBX5LABO",INI(1)))
 .S X1="^INTHL7FT(1,3)" X:$L($G(@X1)) $G(@X1) S X=$E(X,1,999)
 .S @INV@("OBX5")=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"))
 .S:$TR(L1,$G(SUBDELIM))="" L1="" D SETPIECE^INHU(.LINE,DELIM,4,L1,.CP) S L1=$G(@INV@("OBX5")) S:$TR(L1,$G(SUBDELIM))="" L1="" D SETPIECE^INHU(.LINE,DELIM,6,L1,.CP)
 .S LCT=LCT+1,^UTILITY("INH",$J,LCT)=LINE I $D(LINE)>9 M ^UTILITY("INH",$J,LCT)=LINE
 .Q
 S INDA=INDA0 K INDA0
 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