<?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 Set analysis: Count ranges for sums in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Set-analysis-Count-ranges-for-sums/m-p/282189#M496966</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for your help swuehl.&lt;/P&gt;&lt;P&gt; With a few modifications I achieve to do it with with this formula: &lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 12px; color: #636363; font-family: Arial;"&gt;count( aggr( if( SUM(SalesCurrentYear-SalesLastYear) /SUM(SalesLastYear) &amp;gt;= 0.05&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 12px; color: #636363; font-family: Arial;"&gt;and SUM(SalesCurrentYear-SalesLastYear) /SUM(SalesLastYear) &amp;lt;= 0.1, Store), Store))&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 31 Oct 2011 19:40:00 GMT</pubDate>
    <dc:creator />
    <dc:date>2011-10-31T19:40:00Z</dc:date>
    <item>
      <title>Set analysis: Count ranges for sums</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-Count-ranges-for-sums/m-p/282185#M496962</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello everyone,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am new in qlikview and I have an issue in a count a little bit complicated.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have tables with Sales by Product, Banner, Store and Month.&lt;/P&gt;&lt;P&gt;I would like to count the number of store where my goad achievement (SUM(SalesCurrentYear-SalesLastYear) /SUM(SalesLastYear)) are in ranges. So if I select 4 month and for my 200 stores for a few products: &lt;/P&gt;&lt;P&gt;It can count that I have 80 stores under 105% , 60 between 105% and 110% and 60 above 110%. It also want to know that for my 200 store my average is about 105%.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is it possible with set analysis ? Or should I have to rethink my design ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for your help.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 28 Oct 2011 19:54:52 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-Count-ranges-for-sums/m-p/282185#M496962</guid>
      <dc:creator />
      <dc:date>2011-10-28T19:54:52Z</dc:date>
    </item>
    <item>
      <title>Set analysis: Count ranges for sums</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-Count-ranges-for-sums/m-p/282186#M496963</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; lookup IntervalMatch....that may help you get where you wish to.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 28 Oct 2011 20:18:16 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-Count-ranges-for-sums/m-p/282186#M496963</guid>
      <dc:creator />
      <dc:date>2011-10-28T20:18:16Z</dc:date>
    </item>
    <item>
      <title>Set analysis: Count ranges for sums</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-Count-ranges-for-sums/m-p/282187#M496964</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am not sure how I can use this function because It think it is meant to be used in my loading script.&lt;/P&gt;&lt;P&gt;However, when I use my goal achivement it is dynamic:it changes is regarding the stores or the months or the product,... That I have selected. Moreover It cannot be calculated in my script because it is a division of sum.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any other ideas ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for your help.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 31 Oct 2011 12:39:33 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-Count-ranges-for-sums/m-p/282187#M496964</guid>
      <dc:creator />
      <dc:date>2011-10-31T12:39:33Z</dc:date>
    </item>
    <item>
      <title>Set analysis: Count ranges for sums</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-Count-ranges-for-sums/m-p/282188#M496965</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;try maybe something like&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;count( aggr( if( SUM(SalesCurrentYear-SalesLastYear) /SUM(SalesLastYear) &amp;lt; 0.05, Store), Store))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;resp.&lt;/P&gt;&lt;P&gt;count( aggr( if( SUM(SalesCurrentYear-SalesLastYear) /SUM(SalesLastYear) &amp;gt;= 0.05 &lt;/P&gt;&lt;P&gt;and SUM(SalesCurrentYear-SalesLastYear) /SUM(SalesLastYear) &amp;lt;= 0.1, Store), Store))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;resp.&lt;/P&gt;&lt;P&gt;count( aggr( if( SUM(SalesCurrentYear-SalesLastYear) /SUM(SalesLastYear) &amp;gt; 0.1, Store), Store))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for the counts and&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;avg( aggr( SUM(SalesCurrentYear-SalesLastYear) /SUM(SalesLastYear), Store))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for the average.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Since I don't know your data model, you might need to modify these expressions a little (or you maybe you could tell us a little more about your setting, best with uploading a sample).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also note that I used e.g. 10% instead of 110%, since your expression is calculating the surplus only (already subtracting 1 for the last years sales. Or use expressions like sum(SalesCurrentYear) / sum(SalesLastYear) .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Or maybe I misunderstood that requirement, then just change the numbers to whatever you like.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Stefan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 31 Oct 2011 12:56:51 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-Count-ranges-for-sums/m-p/282188#M496965</guid>
      <dc:creator>swuehl</dc:creator>
      <dc:date>2011-10-31T12:56:51Z</dc:date>
    </item>
    <item>
      <title>Set analysis: Count ranges for sums</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-Count-ranges-for-sums/m-p/282189#M496966</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for your help swuehl.&lt;/P&gt;&lt;P&gt; With a few modifications I achieve to do it with with this formula: &lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 12px; color: #636363; font-family: Arial;"&gt;count( aggr( if( SUM(SalesCurrentYear-SalesLastYear) /SUM(SalesLastYear) &amp;gt;= 0.05&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 12px; color: #636363; font-family: Arial;"&gt;and SUM(SalesCurrentYear-SalesLastYear) /SUM(SalesLastYear) &amp;lt;= 0.1, Store), Store))&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 31 Oct 2011 19:40:00 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-Count-ranges-for-sums/m-p/282189#M496966</guid>
      <dc:creator />
      <dc:date>2011-10-31T19:40:00Z</dc:date>
    </item>
    <item>
      <title>Set analysis: Count ranges for sums</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-Count-ranges-for-sums/m-p/282190#M496967</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Good to hear!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;BTW, is above the answer you wanted to mark as correct &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/wink.png" /&gt; ?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 31 Oct 2011 20:55:41 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-Count-ranges-for-sums/m-p/282190#M496967</guid>
      <dc:creator>swuehl</dc:creator>
      <dc:date>2011-10-31T20:55:41Z</dc:date>
    </item>
    <item>
      <title>Re: Set analysis: Count ranges for sums</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-Count-ranges-for-sums/m-p/282191#M496968</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="font-family: trebuchet ms,geneva;"&gt;&lt;EM&gt;&lt;SPAN class="jiveTT-hover-user jive-username-link"&gt;nagrapart - &lt;/SPAN&gt;Please can you mark the right answer as "Correct Answer"? It helps other users while accessing this post.&lt;/EM&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: trebuchet ms,geneva;"&gt;&lt;EM&gt;Thanks in advance.&lt;/EM&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: trebuchet ms,geneva;"&gt;&lt;EM&gt;Cheers - DV&lt;/EM&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 01 Nov 2011 11:15:31 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-Count-ranges-for-sums/m-p/282191#M496968</guid>
      <dc:creator>IAMDV</dc:creator>
      <dc:date>2011-11-01T11:15:31Z</dc:date>
    </item>
  </channel>
</rss>

