String map "" to empty filed

Clovertech Forums Read Only Archives Cloverleaf Cloverleaf String map "" to empty filed

  • Creator
    Topic
  • #49887
    Rick Pritchett
    Participant

      I am trying to us the string map command to change what appears to be an active null in the HL7 testing tool to nothing.  Ex.  |””^^””^””^””| to

      |^^^^|

      set xlateOutVals

        ]

        I can do this for the entire message using a tps regsub proc i have but would rather use the string map command.

        Any ideas?

      Viewing 0 reply threads
      • Author
        Replies
        • #64011
          Tom Rioux
          Participant

            You might want to try this code.  I couldn’t get it to work on an entire field, but it works if you apply it to each subfield.  The issue is the translator sees the double quotes as {}.  So, your code will have to reflect that.  Here is what I used on the subfields to get it to work.  Someone out there may know a better way to get it to work on a whole field at once.

            set xlateOutVals [string map { {} “” } $xlateInVals]

            Hope this helps…

            Tom Rioux

            Baylor Health Care

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