<?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 Re: GetSelectedCount and / or in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/GetSelectedCount-and-or/m-p/871123#M996601</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you, I have the desired result!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 02 Jul 2015 11:12:29 GMT</pubDate>
    <dc:creator />
    <dc:date>2015-07-02T11:12:29Z</dc:date>
    <item>
      <title>GetSelectedCount and / or</title>
      <link>https://community.qlik.com/t5/QlikView/GetSelectedCount-and-or/m-p/871120#M996598</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All I am currently using the following to hide/ show a table:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;GetFieldSelections([Key Figure]) = 'XYZ' and GetSelectedCount(SALES_LEVEL1)&amp;gt;0 or GetSelectedCount(SALES_LEVEL2)&amp;gt;0 or GetSelectedCount([Sales Employee Name])&amp;gt;0 or GetSelectedCount(Account_Name)&amp;gt;0&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This works alongside this in the alternate table:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;GetFieldSelections([Key Figure]) = 'XYZ' &lt;/P&gt;&lt;P&gt;and GetSelectedCount(SALES_LEVEL1)=0 and GetSelectedCount(SALES_LEVEL2)=0 and GetSelectedCount([Sales Employee Name])=0&amp;nbsp; and GetSelectedCount(Account_Name)=0&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;HOWEVER.......&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When a SALES_LEVEL is selected it appears to ignore the 'Key Figure' side of it, so I end up with 2 charts showing at the same time which is strange!!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any ideas?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Jul 2015 10:25:36 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/GetSelectedCount-and-or/m-p/871120#M996598</guid>
      <dc:creator />
      <dc:date>2015-07-02T10:25:36Z</dc:date>
    </item>
    <item>
      <title>Re: GetSelectedCount and / or</title>
      <link>https://community.qlik.com/t5/QlikView/GetSelectedCount-and-or/m-p/871121#M996599</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;You need to be explicit about the order in which the &lt;EM&gt;and&lt;/EM&gt; and &lt;EM&gt;or's &lt;/EM&gt;should be evaluated. Perhaps you meant something like this:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;GetFieldSelections([Key Figure]) = 'XYZ' and &lt;SPAN style="; color: #0000ff;"&gt;&lt;STRONG&gt;(&lt;/STRONG&gt;&lt;/SPAN&gt;GetSelectedCount(SALES_LEVEL1)&amp;gt;0 or GetSelectedCount(SALES_LEVEL2)&amp;gt;0 or GetSelectedCount([Sales Employee Name])&amp;gt;0 or GetSelectedCount(Account_Name)&amp;gt;0&lt;SPAN style="color: #0000ff;"&gt;&lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Jul 2015 10:31:13 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/GetSelectedCount-and-or/m-p/871121#M996599</guid>
      <dc:creator>Gysbert_Wassenaar</dc:creator>
      <dc:date>2015-07-02T10:31:13Z</dc:date>
    </item>
    <item>
      <title>Re: GetSelectedCount and / or</title>
      <link>https://community.qlik.com/t5/QlikView/GetSelectedCount-and-or/m-p/871122#M996600</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The reason why Gysbert is probably right (he usually is) is that all expression operators have an order of precedence when you combine them in the same expression. That means that a multiplication will be executed before an addition, and an 'and' will be evaluated before and 'or'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you want to change this behavior, you should use parentheses to group subexpressions, like in he example solution above. Parentheses don't cost you anything in terms of performance or expression complexity. Better to use too many parentheses than too few.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There is a nice document about Qlik expressions here: &lt;A href="https://community.qlik.com/docs/DOC-8576"&gt;qlik expressions.docx&lt;/A&gt;&lt;/P&gt;&lt;P&gt;See page 3 at the bottom for an operator precedence table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;However, keep in mind that this is not an official Qlik document. I couldn't even find anything like that in the official QlikView documentation (there is one for set analysis operators in the QlikView Reference manual)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Peter&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Jul 2015 10:53:40 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/GetSelectedCount-and-or/m-p/871122#M996600</guid>
      <dc:creator>Peter_Cammaert</dc:creator>
      <dc:date>2015-07-02T10:53:40Z</dc:date>
    </item>
    <item>
      <title>Re: GetSelectedCount and / or</title>
      <link>https://community.qlik.com/t5/QlikView/GetSelectedCount-and-or/m-p/871123#M996601</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you, I have the desired result!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Jul 2015 11:12:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/GetSelectedCount-and-or/m-p/871123#M996601</guid>
      <dc:creator />
      <dc:date>2015-07-02T11:12:29Z</dc:date>
    </item>
  </channel>
</rss>

