Adding sub field

Clovertech Forums Read Only Archives Cloverleaf Cloverleaf Adding sub field

  • Creator
    Topic
  • #51599
    Shibu Mathew
    Participant

      Hello,

      Can someone please direct me on how to add a sub field. I am using a HL7.2.4 variant, but it only has one sub field( 0(0).MSH(0).#9(0).[0]  ) instead of two. How can I add a sub field to MSH.9 so that it will also have the second sub field, 0(0).MSH(0).#9(0).[1]. When I click on the field MSH.9, all I see is,  the type Composite (CM)- please see attached. I am on Cloverleaf 5.7 Rev 1.

      Thank you.

    Viewing 4 reply threads
    • Author
      Replies
      • #70925
        Kevin Crist
        Participant

          What are you trying to do? Copy something to it in an xlate? If so i  think you can just add the .[1]  even if it is not showing but i have never done this with this particular field.

        • #70926
          Robert Milfajt
          Participant

            The number of subfields is a characteristic of data type, but I do not think that matters.

            I agree with Kevin, just make reference to it, and it should work.

            If you really want other subfields, pick another data type for the format, like CE.

            Hope this helps,

            Robert Milfajt
            Northwestern Medicine
            Chicago, IL

          • #70927
            Shibu Mathew
            Participant

              Kevin/Robert,

              yes, I am trying to do an IF based on the value in  MSH.9.2.  I will try using the [1] in the translate and see if that works, if not I will use CE instead of CM.

              Thank you.

            • #70928
              Nick Stainback
              Participant

                If I understand you correctly you have modified the trxid somewhere prior to the xlate and you are trying to then add and IF statement based on the information on the right side of the ^ in MSH9.

                Sounds like you would be better off to change the Trxid in the IBTPS and then just add a different route for each id and apply the different xlates to each route.  

                Hope this helps,

              • #70929
                Jim Kosloskey
                Participant

                  CM is a kind of ‘catch-all’ HL/7 Data Type. It means there can be virtually any number of components or su-components and does not fit any pre-defined structure.

                  It is up to the Trading Partners to agree on the actual structure of the particular field.

                  So in Cloverleaf(R) the only way in an Xlate to reference any component (or sub-component) beyond the first is to type in the appropriate component/sub-component notation.

                  In your case, the use of [1] should be appropriate.

                  email: jim.kosloskey@jim-kosloskey.com 29+ years Cloverleaf, 59 years IT - old fart.

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