<?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: Set Analysis - Filter not applied in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Set-Analysis-Filter-not-applied/m-p/2099487#M90015</link>
    <description>&lt;P&gt;Yes, this is the expected behaviour and it is related to the order of the execution and in which context they are performed. If by the count of ICD a certain selection should be ignored/overwritten this condition must be included in the inside of the expression and depending on view-requirements it might be included within all other stages of the calculation, too.&lt;/P&gt;</description>
    <pubDate>Wed, 02 Aug 2023 11:30:06 GMT</pubDate>
    <dc:creator>marcus_sommer</dc:creator>
    <dc:date>2023-08-02T11:30:06Z</dc:date>
    <item>
      <title>Set Analysis - Filter not applied</title>
      <link>https://community.qlik.com/t5/App-Development/Set-Analysis-Filter-not-applied/m-p/2099447#M90011</link>
      <description>&lt;P&gt;Hello!&lt;/P&gt;
&lt;P&gt;I'm relatively new to Qlik and I currently trying to get a grip on set expressions.&lt;/P&gt;
&lt;P&gt;I have this simple expression:&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Count(&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;{$&amp;lt;Leistungskatalog = {"CAT1"}, [Name] = {"*"}&amp;gt; * &amp;lt;FallBewegungKey = {"=Count(ICD) &amp;gt; 0"}&amp;gt;}&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;DISTINCT Fallnummer)&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;So in other words I want to get all records which match the CAT1 catalogue AND have a count &amp;gt; 0 of a specific measure while ignore the Name selection (I also tried to nullify by leaving the right side empty).&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If I remove the part with the count it's working but as soon as I add the intersection and I select a name, the filter is applied although it should not be.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Count(&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;{$&amp;lt;Leistungskatalog = {"CAT1"}, [Name Arzt] = &amp;gt;}&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;DISTINCT Fallnummer)&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;This works for example. Any hints on what I am missing?&lt;/P&gt;</description>
      <pubDate>Wed, 02 Aug 2023 09:49:36 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Set-Analysis-Filter-not-applied/m-p/2099447#M90011</guid>
      <dc:creator>alliedarmour</dc:creator>
      <dc:date>2023-08-02T09:49:36Z</dc:date>
    </item>
    <item>
      <title>Re: Set Analysis - Filter not applied</title>
      <link>https://community.qlik.com/t5/App-Development/Set-Analysis-Filter-not-applied/m-p/2099461#M90012</link>
      <description>&lt;P&gt;If you want to ignore the Name selection you need to apply this ignoring to all parts like:&lt;/P&gt;
&lt;P&gt;Count(&lt;BR /&gt;{$&amp;lt;Leistungskatalog = {"CAT1"}, [Name]&amp;gt; * &amp;lt;FallBewegungKey = {"=Count(ICD) &amp;gt; 0"}, [Name]&amp;gt;}&lt;BR /&gt;DISTINCT Fallnummer)&lt;/P&gt;
&lt;P&gt;or more simple:&lt;/P&gt;
&lt;P&gt;Count(&lt;BR /&gt;{$&amp;lt;Leistungskatalog = {"CAT1"}, [Name], FallBewegungKey = {"=Count(ICD) &amp;gt; 0"}, [Name]&amp;gt;}&lt;BR /&gt;DISTINCT Fallnummer)&lt;/P&gt;
&lt;P&gt;or in a more logical way like:&lt;/P&gt;
&lt;P&gt;if(Count({&amp;lt; [Name] &amp;gt;} ICD) &amp;gt; 0,&lt;BR /&gt;Count({$&amp;lt;Leistungskatalog = {"CAT1"}, [Name]&amp;gt;}&amp;nbsp;DISTINCT Fallnummer))&lt;/P&gt;
&lt;P&gt;or in further optimized way like:&lt;/P&gt;
&lt;P&gt;sign(Count({&amp;lt; [Name] &amp;gt;} ICD)) *&lt;BR /&gt;Count({$&amp;lt;Leistungskatalog = {"CAT1"}, [Name]&amp;gt;}&amp;nbsp;DISTINCT Fallnummer))&lt;/P&gt;
&lt;P&gt;Beside of this you might be also able to skip the count() part if no ICD records exists or they have the wrong respectively unwanted values - but this would depend on the dataset and the data-model if and how it might be possible.&lt;/P&gt;</description>
      <pubDate>Wed, 02 Aug 2023 10:31:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Set-Analysis-Filter-not-applied/m-p/2099461#M90012</guid>
      <dc:creator>marcus_sommer</dc:creator>
      <dc:date>2023-08-02T10:31:34Z</dc:date>
    </item>
    <item>
      <title>Re: Set Analysis - Filter not applied</title>
      <link>https://community.qlik.com/t5/App-Development/Set-Analysis-Filter-not-applied/m-p/2099476#M90013</link>
      <description>&lt;P&gt;Hi Marcus,&lt;/P&gt;
&lt;P&gt;first, thanks for your answer - ignoring the name in all selections makes sense, so I added the name filter to the second set aswell - but it still doesn't work.&lt;/P&gt;
&lt;P&gt;But what works is if I also put the filter&amp;nbsp; inside the nested count like this:&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Count(&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{$&amp;lt;Leistungskatalog = {"CAT1"}, [Name] = &amp;gt; * &amp;lt;FallBewegungKey = {"=Count(&lt;STRONG&gt;&lt;FONT color="#FF0000"&gt;{$&amp;lt;Name = &amp;gt;}&lt;/FONT&gt;&lt;/STRONG&gt; ICD) &amp;gt; 0"}, [Name] = &amp;gt;}&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;DISTINCT Fallnummer)&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Is this normal / expected behaviour in Qlik Sense?&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 02 Aug 2023 11:12:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Set-Analysis-Filter-not-applied/m-p/2099476#M90013</guid>
      <dc:creator>alliedarmour</dc:creator>
      <dc:date>2023-08-02T11:12:34Z</dc:date>
    </item>
    <item>
      <title>Re: Set Analysis - Filter not applied</title>
      <link>https://community.qlik.com/t5/App-Development/Set-Analysis-Filter-not-applied/m-p/2099487#M90015</link>
      <description>&lt;P&gt;Yes, this is the expected behaviour and it is related to the order of the execution and in which context they are performed. If by the count of ICD a certain selection should be ignored/overwritten this condition must be included in the inside of the expression and depending on view-requirements it might be included within all other stages of the calculation, too.&lt;/P&gt;</description>
      <pubDate>Wed, 02 Aug 2023 11:30:06 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Set-Analysis-Filter-not-applied/m-p/2099487#M90015</guid>
      <dc:creator>marcus_sommer</dc:creator>
      <dc:date>2023-08-02T11:30:06Z</dc:date>
    </item>
  </channel>
</rss>

