<?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: nested aggr - aggr within aggr in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/nested-aggr-aggr-within-aggr/m-p/599135#M221826</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Well, if a three-step dynamic aggregation is what you need - then that &lt;SPAN style="text-decoration: underline;"&gt;&lt;EM&gt;is&lt;/EM&gt;&lt;/SPAN&gt; the way to solve it. &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There is (to my knowledge) no limit to how many nested aggr:s you can have. But every nested aggregation will hit the performance, so you should avoid it if possible.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;HIC &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 19 May 2014 05:51:14 GMT</pubDate>
    <dc:creator>hic</dc:creator>
    <dc:date>2014-05-19T05:51:14Z</dc:date>
    <item>
      <title>nested aggr - aggr within aggr</title>
      <link>https://community.qlik.com/t5/QlikView/nested-aggr-aggr-within-aggr/m-p/599131#M221822</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Is there any pitfalls using aggr within aggr like that:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;avg(total &amp;lt;practice&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; aggr(&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; avg(&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; aggr(&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; avg(score)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ,survey,section&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; )&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; )&lt;/P&gt;&lt;P&gt;&amp;nbsp; ,survey&lt;/P&gt;&lt;P&gt;&amp;nbsp; )&lt;/P&gt;&lt;P&gt;)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I know of performance implications but I am wondering if anyone else actually did that successfully. I cannot find any examples but I tested it quickly and looks like aggr nesting works fine.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 Mar 2014 19:38:35 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/nested-aggr-aggr-within-aggr/m-p/599131#M221822</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-03-04T19:38:35Z</dc:date>
    </item>
    <item>
      <title>Re: nested aggr - aggr within aggr</title>
      <link>https://community.qlik.com/t5/QlikView/nested-aggr-aggr-within-aggr/m-p/599132#M221823</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If the data is correct ...&lt;/P&gt;&lt;P&gt;For some rolling periods, we can do sth like that:&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt; font-family: Arial;"&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;sum&lt;SPAN style="font-size: 8pt; font-family: Arial;"&gt;( &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt; font-family: Arial;"&gt;aggr&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt; font-family: Arial;"&gt;( &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt; font-family: Arial;"&gt;rangesum&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt; font-family: Arial;"&gt;( &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt; font-family: Arial;"&gt;above&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt; font-family: Arial;"&gt;( &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt; font-family: Arial;"&gt;sum&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt; font-family: Arial;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt; font-family: Arial;"&gt;VALUE&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt; font-family: Arial;"&gt;),0,3) ),&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt; font-family: Arial;"&gt;TIME_KEY)&lt;/SPAN&gt;&lt;SPAN style="font-family: Arial; font-size: 8pt;"&gt;)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: Arial; font-size: 8pt;"&gt;As yoi said, performance is not as good as a simple sum() or avr()&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: Arial; font-size: 8pt;"&gt;Fabrice&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt; &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 Mar 2014 20:00:36 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/nested-aggr-aggr-within-aggr/m-p/599132#M221823</guid>
      <dc:creator />
      <dc:date>2014-03-04T20:00:36Z</dc:date>
    </item>
    <item>
      <title>Re: nested aggr - aggr within aggr</title>
      <link>https://community.qlik.com/t5/QlikView/nested-aggr-aggr-within-aggr/m-p/599133#M221824</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;This should work. But why do you want to do it? What's the use-case?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;One single Aggr means a two-step nested aggregation.&lt;/P&gt;&lt;P&gt;Two nested Aggr's would mean a &lt;SPAN style="text-decoration: underline;"&gt;&lt;EM&gt;three-step&lt;/EM&gt;&lt;/SPAN&gt; nested aggregation.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;HIC &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 18 May 2014 20:37:02 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/nested-aggr-aggr-within-aggr/m-p/599133#M221824</guid>
      <dc:creator>hic</dc:creator>
      <dc:date>2014-05-18T20:37:02Z</dc:date>
    </item>
    <item>
      <title>Re: nested aggr - aggr within aggr</title>
      <link>https://community.qlik.com/t5/QlikView/nested-aggr-aggr-within-aggr/m-p/599134#M221825</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Henric,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I was surprised it would work but it does work fine!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;my use case was exactly that - three level aggregation. I was working with some survey data (questions/answers) and the requirement was to calculate overall organization's score as a mean of means of all survey sections answers (group of questions). Then in turn, means of sections answers are calculated as means of each individual question scores in each section. So it is a mean of means of means. I considered doing this in a script but the requirement was to calculate the final score on the fly and respect selections.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I did not have a lot of data (a couple million rows with each survey's answer score) and the performance was actually very good - granted we have quite a powerful server.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 19 May 2014 01:24:52 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/nested-aggr-aggr-within-aggr/m-p/599134#M221825</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-05-19T01:24:52Z</dc:date>
    </item>
    <item>
      <title>Re: nested aggr - aggr within aggr</title>
      <link>https://community.qlik.com/t5/QlikView/nested-aggr-aggr-within-aggr/m-p/599135#M221826</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Well, if a three-step dynamic aggregation is what you need - then that &lt;SPAN style="text-decoration: underline;"&gt;&lt;EM&gt;is&lt;/EM&gt;&lt;/SPAN&gt; the way to solve it. &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There is (to my knowledge) no limit to how many nested aggr:s you can have. But every nested aggregation will hit the performance, so you should avoid it if possible.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;HIC &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 19 May 2014 05:51:14 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/nested-aggr-aggr-within-aggr/m-p/599135#M221826</guid>
      <dc:creator>hic</dc:creator>
      <dc:date>2014-05-19T05:51:14Z</dc:date>
    </item>
  </channel>
</rss>

