complex gyui xlate if statement

Clovertech Forums Read Only Archives Cloverleaf Cloverleaf complex gyui xlate if statement

  • Creator
    Topic
  • #51905
    Bob Schmid
    Participant

      1(0).1(0).1(%g1).OBX.#2 eq =TX && ( 1(0).1(0).1(%g1).OBX.#11 eq =@null || 1(0).1(0).1(%g1).OBX.#3.[0] eq=COMNT )    

      want it if A and (b or c)

      invalid…why

      error message

      [0:TEST] IF expression parse failed: Syntax error; token out of sequence

      Error occurred at: ‘l || 1(0).1(0).1(%g1).OBX.#3.[0] eq=COMNT )’

      [0:TEST] Unable to compile XLT ‘Sunquest_to_Epic_R01_ORU.xlt’.

    Viewing 1 reply thread
    • Author
      Replies
      • #72210
        Jim Kosloskey
        Participant

          Robert,

          I think you need a space between the eq and =COMT

          Old:

          1(0).1(0).1(%g1).OBX.#3.[0] eq=COMNT )

          New:

          1(0).1(0).1(%g1).OBX.#3.[0] eq =COMNT )

          email: jim.kosloskey@jim-kosloskey.com 30+ years Cloverleaf, 60 years IT – old fart.

        • #72211
          Tom Rioux
          Participant

            Robert,

            Also, one other thing that may or may not make a difference.   When we use the @null variable in an IF statement, we do so without the = sign.  Not sure what will happen with it in there.   This is how we do it here:

            1(0).1(0).1(%g1).OBX.#11 eq @null

            Hope this helps…

            Tom

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