<?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 Sum Aggr and Count with Multiple If Else Conditions in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Sum-Aggr-and-Count-with-Multiple-If-Else-Conditions/m-p/1732635#M452409</link>
    <description>&lt;P&gt;Good Day All,&lt;/P&gt;&lt;P&gt;I am working on store related data and i have to calculate &lt;STRONG&gt;compliance&lt;/STRONG&gt; on each visit for a KPI but the problem is we have different store types with different criteria applied on it.&lt;/P&gt;&lt;P&gt;I have write below expression but there is some mistake in it, can you please help me out where i am making the mistake.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Expression:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000FF"&gt;sum&lt;/FONT&gt;(&lt;FONT color="#0000FF"&gt;aggr&lt;/FONT&gt;(&lt;BR /&gt;&lt;FONT color="#0000FF"&gt;If&lt;/FONT&gt;(&lt;FONT color="#0000FF"&gt;count&lt;/FONT&gt;&lt;BR /&gt;(&lt;FONT color="#0000FF"&gt;distinct&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF"&gt;if&lt;/FONT&gt;&lt;BR /&gt;(&lt;FONT color="#993300"&gt;Parameter&lt;/FONT&gt;='KPI-1' &lt;FONT color="#0000FF"&gt;and&lt;/FONT&gt; &lt;FONT color="#993300"&gt;Compliance&lt;/FONT&gt;='C' &lt;FONT color="#0000FF"&gt;and&lt;/FONT&gt; &lt;FONT color="#993300"&gt;Store_Type&lt;/FONT&gt;&amp;lt;&amp;gt;'Cosmetics',&lt;FONT color="#993300"&gt;Category&lt;/FONT&gt;)&lt;BR /&gt;)&amp;gt;=5,1,&lt;FONT color="#0000FF"&gt;if&lt;/FONT&gt;(&lt;FONT color="#993300"&gt;Parameter&lt;/FONT&gt;='KPI-1' &lt;FONT color="#0000FF"&gt;and&lt;/FONT&gt; &lt;FONT color="#993300"&gt;Compliance&lt;/FONT&gt;='C' &lt;FONT color="#0000FF"&gt;and&lt;/FONT&gt; &lt;FONT color="#993300"&gt;Store_Type&lt;/FONT&gt;='Cosmetics',&lt;FONT color="#993300"&gt;Category&lt;/FONT&gt;)&amp;gt;=2,1)&lt;BR /&gt;,Visit,Compliance))&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Criteria:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Grocers =5, Cosmetics=2&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-right" image-alt="Qlik Issue SOS.jpg" style="width: 999px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/38434i1608FAD2E351EEDA/image-size/large?v=v2&amp;amp;px=999" role="button" title="Qlik Issue SOS.jpg" alt="Qlik Issue SOS.jpg" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Sat, 16 Nov 2024 00:12:27 GMT</pubDate>
    <dc:creator>danyal1990</dc:creator>
    <dc:date>2024-11-16T00:12:27Z</dc:date>
    <item>
      <title>Sum Aggr and Count with Multiple If Else Conditions</title>
      <link>https://community.qlik.com/t5/QlikView/Sum-Aggr-and-Count-with-Multiple-If-Else-Conditions/m-p/1732635#M452409</link>
      <description>&lt;P&gt;Good Day All,&lt;/P&gt;&lt;P&gt;I am working on store related data and i have to calculate &lt;STRONG&gt;compliance&lt;/STRONG&gt; on each visit for a KPI but the problem is we have different store types with different criteria applied on it.&lt;/P&gt;&lt;P&gt;I have write below expression but there is some mistake in it, can you please help me out where i am making the mistake.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Expression:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000FF"&gt;sum&lt;/FONT&gt;(&lt;FONT color="#0000FF"&gt;aggr&lt;/FONT&gt;(&lt;BR /&gt;&lt;FONT color="#0000FF"&gt;If&lt;/FONT&gt;(&lt;FONT color="#0000FF"&gt;count&lt;/FONT&gt;&lt;BR /&gt;(&lt;FONT color="#0000FF"&gt;distinct&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF"&gt;if&lt;/FONT&gt;&lt;BR /&gt;(&lt;FONT color="#993300"&gt;Parameter&lt;/FONT&gt;='KPI-1' &lt;FONT color="#0000FF"&gt;and&lt;/FONT&gt; &lt;FONT color="#993300"&gt;Compliance&lt;/FONT&gt;='C' &lt;FONT color="#0000FF"&gt;and&lt;/FONT&gt; &lt;FONT color="#993300"&gt;Store_Type&lt;/FONT&gt;&amp;lt;&amp;gt;'Cosmetics',&lt;FONT color="#993300"&gt;Category&lt;/FONT&gt;)&lt;BR /&gt;)&amp;gt;=5,1,&lt;FONT color="#0000FF"&gt;if&lt;/FONT&gt;(&lt;FONT color="#993300"&gt;Parameter&lt;/FONT&gt;='KPI-1' &lt;FONT color="#0000FF"&gt;and&lt;/FONT&gt; &lt;FONT color="#993300"&gt;Compliance&lt;/FONT&gt;='C' &lt;FONT color="#0000FF"&gt;and&lt;/FONT&gt; &lt;FONT color="#993300"&gt;Store_Type&lt;/FONT&gt;='Cosmetics',&lt;FONT color="#993300"&gt;Category&lt;/FONT&gt;)&amp;gt;=2,1)&lt;BR /&gt;,Visit,Compliance))&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Criteria:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Grocers =5, Cosmetics=2&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-right" image-alt="Qlik Issue SOS.jpg" style="width: 999px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/38434i1608FAD2E351EEDA/image-size/large?v=v2&amp;amp;px=999" role="button" title="Qlik Issue SOS.jpg" alt="Qlik Issue SOS.jpg" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 16 Nov 2024 00:12:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sum-Aggr-and-Count-with-Multiple-If-Else-Conditions/m-p/1732635#M452409</guid>
      <dc:creator>danyal1990</dc:creator>
      <dc:date>2024-11-16T00:12:27Z</dc:date>
    </item>
    <item>
      <title>Re: Sum Aggr and Count with Multiple If Else Conditions</title>
      <link>https://community.qlik.com/t5/QlikView/Sum-Aggr-and-Count-with-Multiple-If-Else-Conditions/m-p/1732637#M452410</link>
      <description>&lt;P&gt;How you are getting total visit as 4?&lt;/P&gt;</description>
      <pubDate>Sun, 02 Aug 2020 14:50:13 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sum-Aggr-and-Count-with-Multiple-If-Else-Conditions/m-p/1732637#M452410</guid>
      <dc:creator>Kushal_Chawda</dc:creator>
      <dc:date>2020-08-02T14:50:13Z</dc:date>
    </item>
    <item>
      <title>Re: Sum Aggr and Count with Multiple If Else Conditions</title>
      <link>https://community.qlik.com/t5/QlikView/Sum-Aggr-and-Count-with-Multiple-If-Else-Conditions/m-p/1732642#M452412</link>
      <description>&lt;P&gt;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/336"&gt;@Kushal_Chawda&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;For Total Visits:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;=&lt;FONT color="#0000FF"&gt;Sum&lt;/FONT&gt;(&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;FONT color="#0000FF"&gt;Aggr&lt;/FONT&gt;(&lt;FONT color="#0000FF"&gt;Count&lt;/FONT&gt;(&lt;FONT color="#0000FF"&gt;DISTINCT&lt;/FONT&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;FONT color="#0000FF"&gt;if&lt;/FONT&gt;(&lt;FONT color="#993300"&gt;Parameter&lt;/FONT&gt;='KPI-1',&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;FONT color="#993300"&gt;Visit&lt;/FONT&gt;)),&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;FONT color="#993300"&gt;Storecode&lt;/FONT&gt;))&lt;/P&gt;</description>
      <pubDate>Sun, 02 Aug 2020 15:51:26 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sum-Aggr-and-Count-with-Multiple-If-Else-Conditions/m-p/1732642#M452412</guid>
      <dc:creator>danyal1990</dc:creator>
      <dc:date>2020-08-02T15:51:26Z</dc:date>
    </item>
    <item>
      <title>Re: Sum Aggr and Count with Multiple If Else Conditions</title>
      <link>https://community.qlik.com/t5/QlikView/Sum-Aggr-and-Count-with-Multiple-If-Else-Conditions/m-p/1733206#M452443</link>
      <description>&lt;P&gt;You can try below&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;sum(aggr(if(Count({&amp;lt;Parameter={'KPI-1'},Compliance={'C'},Store_Type={'Grocers'}&amp;gt;}Visit)&amp;gt;=5,1),Store_Type,Compliance,Visit))+
sum(aggr(if(Count({&amp;lt;Parameter={'KPI-1'},Compliance={'C'},Store_Type={'Cosmetics'}&amp;gt;}Visit)&amp;gt;=2,1),Store_Type,Compliance,Visit))&lt;/LI-CODE&gt;</description>
      <pubDate>Tue, 04 Aug 2020 16:04:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sum-Aggr-and-Count-with-Multiple-If-Else-Conditions/m-p/1733206#M452443</guid>
      <dc:creator>Kushal_Chawda</dc:creator>
      <dc:date>2020-08-04T16:04:37Z</dc:date>
    </item>
  </channel>
</rss>

