Announcement

Collapse
No announcement yet.

Changing HL7 version 2.3 to 2.5

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Changing HL7 version 2.3 to 2.5

    I need to convert HL7 version 2.3 to 2.5. I was trying to do this in the Pre Processing Script but it's not working or maybe I don't know how to make it work. I already have one script in my pre processing block which is;

    message = message.replace("|ORU|", "|ORU^R01|");
    return message;

    How can I add another pre process script in converting MSH 12 2.3 to 2.5?



    Thanks!

  • #2
    Re: Changing HL7 version 2.3 to 2.5

    Try:
    Code:
    message=message.replace("|ORU|", "|ORU^R01|");
    message=message.replace(/\|2\.3/i,'|2.5|');
    return message;

    Comment


    • #3
      Re: Changing HL7 version 2.3 to 2.5

      Sir,

      Oh, it changed. I'm having a status of REJECTED.

      Thanks!

      Comment


      • #4
        Re: Changing HL7 version 2.3 to 2.5

        Code:
        message=message.replace("|ORU|", "|ORU^R01|");
        message=message.replace(/\|2\.3\|/i,'|2.5|');
        return message;
        Try that - is REJECTED expected?
        Chris Lang

        Comment


        • #5
          Re: Changing HL7 version 2.3 to 2.5

          Chris,

          the code you gave did not convert 2.3 to 2.5. The REJECTED status awhile ago was due to the previous code given. When REJECTED, it is not displaying the Encoded Message.

          Thanks!

          Comment


          • #6
            Re: Changing HL7 version 2.3 to 2.5

            Did the original code (Alberto's) work ok for you?
            Chris Lang

            Comment


            • #7
              Re: Changing HL7 version 2.3 to 2.5

              No, sir. It resulted in a REJECTED status.


              Thanks

              Comment


              • #8
                Re: Changing HL7 version 2.3 to 2.5

                What does your filter look like? Is it checking a message type/version?
                Chris Lang

                Comment


                • #9
                  Re: Changing HL7 version 2.3 to 2.5

                  Please, could you post your Channel definition, and an message input example ?

                  Comment


                  • #10
                    Re: Changing HL7 version 2.3 to 2.5

                    Here's my sample message being inputed;

                    MSH|^~\&|1100|HD|ORC|HD000158|200605190839||ORU^R0 1|0964|P|2.3
                    PID|1|461288875|10804311310|461288875|SURNAME^GIVE NNAME||19250623|M||||||||||42101465^^^03^^F|551231 233
                    ORC|RE|604170348^LAB|10804311310^LAB||||||20060418 0000|||^NORTHWEST^T
                    OBR|1|604170348^LAB|10804311310^LAB|188243^Fungus Culture With Stain^L|||200604171432|||||||200604180000||||60417 0348||604170348||200605190839||BN|F
                    OBX|1|ST|188244^Fungus Stain^L||Final report|||||N|F|||200604221513|BN
                    ORC|RE|604170348^LAB|10804311310^LAB||||||20060418 0000|||^NORTHWEST^T
                    OBR|2|604170348^LAB|10804311310^LAB|080564^Result^ L|||200604171432||||G|||200604180000||||604170348| |604170348||200605190839||BN|F|080564|||188243
                    OBX|1|TX|080565^Result 1^L||Comment|||||N|F|||200604221513|BN
                    NTE|1|L|KOH/Calcofluor preparation: no fungus observed.
                    ORC|RE|604170348^LAB|10804311310^LAB||||||20060418 0000|||^NORTHWEST^T
                    OBR|3|604170348^LAB|10804311310^LAB|188243^Fungus Culture With Stain^L|||200604171432|||||||200604180000||||60417 0348||604170348||200605190839||BN|F
                    OBX|1|ST|008482^Fungus (Mycology) Culture^L||Final report|||||N|F|||200605190721|BN
                    ORC|RE|604170348^LAB|10804311310^LAB||||||20060418 0000|||^NORTHWEST^T
                    OBR|4|604170348^LAB|10804311310^LAB|080092^Result^ L|||200604171432||||G|||200604180000||||604170348| |604170348||200605190839||BN|F|080092|||188243
                    OBX|1|TX|080094^Result 1^L||Comment|||||N|F|||200605190721|BN
                    NTE|1|L|NO YEAST OR MOLD ISOLATED AFTER 4 WEEKS.
                    ORC|RE|604170348^LAB|10804311310^LAB||||||20060418 0000|||^NORTHWEST^T
                    OBR|5|604170348^LAB|10804311310^LAB|182402^AFB Culture and Smear,Broth^L|||200604171432|||||||200604180000||| |604170348||604170348||200605190839||BN|X
                    OBX|1|TX|182402^AFB Culture and Smear,Broth^L||Test Not Performed.|||||N|X|||200605111525|BN
                    NTE|1|L|Test Not Performed. Specimen deterioration or loss has
                    NTE|2|L|occurred such that testing is no longer possible.
                    ORC|RE|604170348^LAB|10804311310^LAB||||||20060418 0000|||^NORTHWEST^T
                    OBR|6|604170348^LAB|10804311310^LAB|977032^Referen ce Micro Problem Test^L|||200604171432|||||||200604180000||||604170 348||604170348||200605190839||BN|X
                    OBX|1|ST|977032^Reference Micro Problem Test^L||Comment:|||||N|X|||200605111525|BN
                    NTE|1|L|Test Not Performed. Specimen deterioration or loss has
                    NTE|2|L|occurred such that testing is no longer possible.
                    NTE|3|L| TEST: 182402 AFB Culture and Smear,Broth
                    NTE|4|L| CLIENT CONTACTED 5/11/06 @3:10PM (JACOB N.).
                    ZPS|1|BN|LabCorp Burlington|1447 York Court^^Burlington^NC^272152230|8882005439||MD^Hanc ock^Frank^^^^MD

                    Comment


                    • #11
                      Re: Changing HL7 version 2.3 to 2.5

                      Can you export your channel as well?
                      Chris Lang

                      Comment


                      • #12
                        Re: Changing HL7 version 2.3 to 2.5

                        I don't know why the message is set to REJECTED...

                        But, I've tested your message in a simple channel, and and all works fine with the next preprocessor:

                        Code:
                        message=message.replace(/\|2\.3/i,'|2.5');
                        return message;
                        In the message you've posted there was no '|' ending at the version number, and the message type was set to ORU^R01, so the first step is no longer needed.

                        Comment


                        • #13
                          Re: Changing HL7 version 2.3 to 2.5

                          Bobbit - The rejected status is due to your Filter script rejecting the message. Check your code there and make sure you are using the right mappings for the message type. If you wrote your filter against version 2.3, but are changing the message to 2.5, you might run into issues with different segment orders/names/etc. causing your filter to reject otherwise valid messages.

                          -Chris
                          Chris Lang

                          Comment


                          • #14
                            Re: Changing HL7 version 2.3 to 2.5

                            Thanks Chris and Alberto, it's working now. The code in my filter is checking MSH 9 for R01 which was in version 2.3. I just drag the one that came from version 2.5 at it worked. Thank you very much!

                            Comment


                            • #15
                              Re: Changing HL7 version 2.3 to 2.5

                              Quick question:

                              This thread seems to indicate that you only have to change the Message Type string and Version ID in the MSH segment and Mirth will automatically convert the message between HL7 versions. Is that right? Does it handle all the work of mapping between changed data types in the various HL7 versions? How does it decide how to map from one representation to another?

                              Thanks.

                              -Jim

                              Comment

                              Working...
                              X