Blanking an Active null

Clovertech Forums Read Only Archives Cloverleaf Cloverleaf Blanking an Active null

  • Creator
    Topic
  • #48240
    Keith McLeod
    Participant

      I need to blank out an active null.  I have a request that if PV1:3 is an active null, then blank it out.  I would liike to do this within a translate.  Any ideas?

    Viewing 4 reply threads
    • Author
      Replies
      • #58121
        James Cobane
        Participant

          Keith,

          I’m assuming that when you state “blank out an active null” you want to make |””| into ||   is that correct?  If so, then you can do this within an Xlate; you should be able to value a temp field with “” with a COPY statement:

          COPY =”” —> @myactivenull

          (The engine will then apply the backslash escape characters when you click the apply button, so you’ll see =””)

          You can then just use an IF statement to compare if your input field is equal to @myactivenull and then copy @null when the condition is true:

          IF  0(0).PV1.00053.[0]  eq @myactivenull

           COPY @null —> 0(0).PV1.00053.[0]

          Hope this helps.

          Jim Cobane

          Henry Ford Health

        • #58122
          Michael Lacriola
          Participant

            copy statement using @null as source value and the field you want nulled in the destination.

          • #58123
            Keith McLeod
            Participant

              I ended up establishing a proc that sets a flag if $xlateInTypes ==

            • #58124
              Alice Kazin
              Participant

                If the value of first occurrence of xlateOutTypes is null, I set it to “ch”

                If {[lindex $xlateOutTypes 0] == “null”} {

                  set xlateOutTypes

                  }

              • #58125
                Charlie Bursell
                Participant

                  These answers will not always work.  The problem here is not the contents of the field but the field type.  A true Active Null field has a type of null.  To make it a real null you must change the type.  So you may have to do something like:

                  set xlateOutTypes

                •    ;# *NEVER* foget these are lists!

                  set xalteOutVals

                    The above assume only a single subfield

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