Translation failing due to incorrectly ordered segments

Clovertech Forums Read Only Archives Cloverleaf Cloverleaf Translation failing due to incorrectly ordered segments

  • Creator
    Topic
  • #53718
    Matthew Laskin
    Participant

      When testing a simple ADT translation, I ran into an issue where the testing tool is failing my translation due to incorrectly ordered segments.  I originally had the outbound variant setup with just the three segments MSH PID and PV1, which was causing errors.  I reconfigured the translation with the default variant for ADT, re-tested and didn’t have a problem.  The outbound message actually looked like what I wanted, except that it included the EVN segment.  I tried changing the EVN segment to “Optional” and again got the error.  If the purpose of the variant is to define the segments I want in the message, why should the EVN segment be required?   Take a look:

      see first attachment

      Code:

      MESSAGE 1
      [0:TEST] [mid:0x1e663ac] The # 1 segment encountered ‘PID’ is out of order for message type ‘ADT_A04’.  Segment ignored.
      [0:TEST] [mid:0x1e663ac] The # 2 segment encountered ‘PV1’ is out of order for message type ‘ADT_A04’.  Segment ignored.
      0(0).MSH(0)  :  >|^~&|ADM|GBMC|||201306251618||ADT^A04|48984|D|2.2|||AL|NE<

      and

      see second attachment

      Code:



      MESSAGE 1
      0(0).MSH(0)  :  >|^~&|ADM|GBMC|||201306251618||ADT^A04|48984|D|2.2|||AL|NE< 0(0).EVN(0)  :  >< 0(0).PID(0)  :  >|1|GBDTVIF0000110|M000000108||INTERFACE^ECW||19990204|M||||||||||V00000000134< 0(0).PV1(0)  :  >|1|O|LABDC|O|||LAM.MA^test^PI^A^^^M.D.|||||||||||RE|||||||||||||||||||||GB||RE|||201306251618<

    Viewing 2 reply threads
    • Author
      Replies
      • #78721
        Boris Perov
        Participant

          I would go ahead and make the EVN segment “optional” for each ADT message type you’re likely to see…

        • #78722
          Robert Kersemakers
          Participant

            First try putting your test message through the HL7 tester, against the inbound variant. Does it give an error as well?

            If your inbound message doesn’t have an EVN segment, then you should make EVN optional in your inbound variant.

            Zuyderland Medisch Centrum; Heerlen/Sittard; The Netherlands

          • #78723
            Matthew Laskin
            Participant

              Right – adding EVN as optional fixes the translation error.  I was under the impression that a variant did not have requirements outside of what is defined in the format.

              Thanks both for looking it over 😀

          Viewing 2 reply threads
          • The forum ‘Cloverleaf’ is closed to new topics and replies.