Skip to main content
Inspiring
November 28, 2013
Question

cfif with or problem

  • November 28, 2013
  • 1 reply
  • 646 views

hi

i'm trying to use multiple expressions in a cfif

ex:

<cfif (Evaluate(test.itemcode) is not "HDMI") OR (Evaluate(itemcode) is not "DVI")>

this should result in returning everything that 's not with hdmi or dvi , right? it doesn't , it returns everything including them

but when I do:

<cfif (Evaluate(test.itemcode) is not "HDMI")>

it excludes the hdmi from the list...

what am I doing wrong?

    This topic has been closed for replies.

    1 reply

    Participating Frequently
    November 28, 2013

    Don't use evaluate!  And I think you should be using an AND instead of an OR (I might have misunderstood your requirements though)

    <cfif test.itemcode is not "HDMI" AND itemcode is not "DVI">

    BenuttiAuthor
    Inspiring
    November 28, 2013

    Then why does the evaluate work if there's only 1 requirement?

    Or it has to be.. i want to exclude the hdmi and dvi

    Verzonden vanaf Samsung Mobile

    <div