<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Order of operations for logical operators? in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Order-of-operations-for-logical-operators/m-p/291385#M108160</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;For the logical operators (and, or, not, xor), what is the order of operations?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For example, if I say &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;condition1 or condition2 and condition3&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Will it evaluate as &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;(condition1 or condition2) and condition3&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;or&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;condition1 or (condition2 and condition3)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also, is it possible to use parentheses to change that behavior?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 09 Dec 2011 20:03:07 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2011-12-09T20:03:07Z</dc:date>
    <item>
      <title>Order of operations for logical operators?</title>
      <link>https://community.qlik.com/t5/QlikView/Order-of-operations-for-logical-operators/m-p/291385#M108160</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;For the logical operators (and, or, not, xor), what is the order of operations?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For example, if I say &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;condition1 or condition2 and condition3&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Will it evaluate as &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;(condition1 or condition2) and condition3&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;or&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;condition1 or (condition2 and condition3)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also, is it possible to use parentheses to change that behavior?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 09 Dec 2011 20:03:07 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Order-of-operations-for-logical-operators/m-p/291385#M108160</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2011-12-09T20:03:07Z</dc:date>
    </item>
    <item>
      <title>Re: Order of operations for logical operators?</title>
      <link>https://community.qlik.com/t5/QlikView/Order-of-operations-for-logical-operators/m-p/291386#M108161</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;While I don't see it in the documentation, I would expect QlikView to implement the "standard" order of operations.&amp;nbsp; In other words (and I'm sure I'm missing some, and might have something wrong):&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;terms inside parentheses&lt;/LI&gt;&lt;LI&gt;multiplication and division&lt;/LI&gt;&lt;LI&gt;addition and subtraction&lt;/LI&gt;&lt;LI&gt;comparisons&lt;/LI&gt;&lt;LI&gt;not&lt;/LI&gt;&lt;LI&gt;and&lt;/LI&gt;&lt;LI&gt;or&lt;/LI&gt;&lt;LI&gt;assignment&lt;/LI&gt;&lt;LI&gt;left to right&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This should also answer your question about parentheses.&amp;nbsp; Yes, you can override with parentheses because they come first in the order of operations.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But why even ask when you can so easily test?&amp;nbsp; Type some expressions in and see what happens.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 09 Dec 2011 20:25:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Order-of-operations-for-logical-operators/m-p/291386#M108161</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2011-12-09T20:25:27Z</dc:date>
    </item>
    <item>
      <title>Re: Order of operations for logical operators?</title>
      <link>https://community.qlik.com/t5/QlikView/Order-of-operations-for-logical-operators/m-p/2455699#M1225712</link>
      <description>&lt;P&gt;I think, one of the big purposes of a community is to document the stuff not documented, so thousands of people don't all have to waste time testing to trial and error how something works&lt;/P&gt;</description>
      <pubDate>Thu, 23 May 2024 13:40:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Order-of-operations-for-logical-operators/m-p/2455699#M1225712</guid>
      <dc:creator>Ken_T</dc:creator>
      <dc:date>2024-05-23T13:40:01Z</dc:date>
    </item>
  </channel>
</rss>

