<?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 Nested Aggregations and Drill Down Groups in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Nested-Aggregations-and-Drill-Down-Groups/m-p/675051#M475279</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is it possible to perform different aggregations at different stages of a drill down group? I am working on a list of parts where the average price needs to be shown at the part level and the sum of the average price needs to be shown at the site level (the site that manufactured the parts. You can total an average at the bottom of the table when viewing the part level, but when you zoomed out to the site level I can only see how to show the average price of all parts manufactured on that site.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The function I am using is basically avg(price). sum(avg(price)) breaks the column so I'm guessing Qlikview doesn't like nested aggregations. Is there a way around this?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Required Result:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Part Level:&lt;/P&gt;&lt;TABLE border="1" class="jiveBorder" height="119.39999997615814" style="border: 1px solid #000000; width: 292.39999997615814px; height: 113.39999997615814px;"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;&lt;STRONG&gt;Part&lt;/STRONG&gt;&lt;/TH&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;Avg Price&lt;/TH&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px; text-align: center;"&gt;A&lt;/TD&gt;&lt;TD style="padding: 2px; text-align: center;"&gt;2&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px; text-align: center;"&gt;B&lt;/TD&gt;&lt;TD style="padding: 2px; text-align: center;"&gt;1&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px; text-align: center;"&gt;Total&lt;/TD&gt;&lt;TD style="padding: 2px; text-align: center;"&gt;3&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Site Level:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE border="1" class="jiveBorder" height="71.39999997615814" style="border: 1px solid #000000; width: 294.39999997615814px; height: 60.39999997615814px;"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;&lt;STRONG&gt;Site&lt;/STRONG&gt;&lt;/TH&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;Total Price&lt;/TH&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px; text-align: center;"&gt;Lon&lt;/TD&gt;&lt;TD style="padding: 2px; text-align: center;"&gt;3&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px; text-align: center;"&gt;Bham&lt;/TD&gt;&lt;TD style="padding: 2px; text-align: center;"&gt;3&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;(A &amp;amp; B made in Lon, C made in Bham)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 29 Jul 2014 14:55:11 GMT</pubDate>
    <dc:creator>matthewjbryant</dc:creator>
    <dc:date>2014-07-29T14:55:11Z</dc:date>
    <item>
      <title>Nested Aggregations and Drill Down Groups</title>
      <link>https://community.qlik.com/t5/QlikView/Nested-Aggregations-and-Drill-Down-Groups/m-p/675051#M475279</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is it possible to perform different aggregations at different stages of a drill down group? I am working on a list of parts where the average price needs to be shown at the part level and the sum of the average price needs to be shown at the site level (the site that manufactured the parts. You can total an average at the bottom of the table when viewing the part level, but when you zoomed out to the site level I can only see how to show the average price of all parts manufactured on that site.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The function I am using is basically avg(price). sum(avg(price)) breaks the column so I'm guessing Qlikview doesn't like nested aggregations. Is there a way around this?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Required Result:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Part Level:&lt;/P&gt;&lt;TABLE border="1" class="jiveBorder" height="119.39999997615814" style="border: 1px solid #000000; width: 292.39999997615814px; height: 113.39999997615814px;"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;&lt;STRONG&gt;Part&lt;/STRONG&gt;&lt;/TH&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;Avg Price&lt;/TH&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px; text-align: center;"&gt;A&lt;/TD&gt;&lt;TD style="padding: 2px; text-align: center;"&gt;2&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px; text-align: center;"&gt;B&lt;/TD&gt;&lt;TD style="padding: 2px; text-align: center;"&gt;1&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px; text-align: center;"&gt;Total&lt;/TD&gt;&lt;TD style="padding: 2px; text-align: center;"&gt;3&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Site Level:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE border="1" class="jiveBorder" height="71.39999997615814" style="border: 1px solid #000000; width: 294.39999997615814px; height: 60.39999997615814px;"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;&lt;STRONG&gt;Site&lt;/STRONG&gt;&lt;/TH&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;Total Price&lt;/TH&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px; text-align: center;"&gt;Lon&lt;/TD&gt;&lt;TD style="padding: 2px; text-align: center;"&gt;3&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px; text-align: center;"&gt;Bham&lt;/TD&gt;&lt;TD style="padding: 2px; text-align: center;"&gt;3&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;(A &amp;amp; B made in Lon, C made in Bham)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 29 Jul 2014 14:55:11 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Nested-Aggregations-and-Drill-Down-Groups/m-p/675051#M475279</guid>
      <dc:creator>matthewjbryant</dc:creator>
      <dc:date>2014-07-29T14:55:11Z</dc:date>
    </item>
    <item>
      <title>Re: Nested Aggregations and Drill Down Groups</title>
      <link>https://community.qlik.com/t5/QlikView/Nested-Aggregations-and-Drill-Down-Groups/m-p/675052#M475280</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;i don´t understand the issue exactly, but can´t you solve it with a pivot table? &lt;/P&gt;&lt;P&gt;basically i would say aggr is the expression needed&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 29 Jul 2014 15:03:43 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Nested-Aggregations-and-Drill-Down-Groups/m-p/675052#M475280</guid>
      <dc:creator>michael_maeuser</dc:creator>
      <dc:date>2014-07-29T15:03:43Z</dc:date>
    </item>
    <item>
      <title>Re: Nested Aggregations and Drill Down Groups</title>
      <link>https://community.qlik.com/t5/QlikView/Nested-Aggregations-and-Drill-Down-Groups/m-p/675053#M475281</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;"&gt;Hi Matthew, &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&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;"&gt;I don´t understand the issue exactly, maybe you need:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;1- Create a variable =GetCurrentField("Name_&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;drill _down _group"&lt;/SPAN&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;"&gt;2_&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;sum(aggr(avg(price),$(variable))&lt;/SPAN&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;"&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;"&gt;ale.-&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;"&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;"&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;"&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/SPAN&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;"&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;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 29 Jul 2014 15:12:12 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Nested-Aggregations-and-Drill-Down-Groups/m-p/675053#M475281</guid>
      <dc:creator>male_carrasco</dc:creator>
      <dc:date>2014-07-29T15:12:12Z</dc:date>
    </item>
    <item>
      <title>Re: Nested Aggregations and Drill Down Groups</title>
      <link>https://community.qlik.com/t5/QlikView/Nested-Aggregations-and-Drill-Down-Groups/m-p/675054#M475282</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Just using a pivot will not solve the problem. Can you help me to understand how the aggr function could assist me here?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 29 Jul 2014 15:12:23 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Nested-Aggregations-and-Drill-Down-Groups/m-p/675054#M475282</guid>
      <dc:creator>matthewjbryant</dc:creator>
      <dc:date>2014-07-29T15:12:23Z</dc:date>
    </item>
    <item>
      <title>Re: Nested Aggregations and Drill Down Groups</title>
      <link>https://community.qlik.com/t5/QlikView/Nested-Aggregations-and-Drill-Down-Groups/m-p/675055#M475283</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It doesn't work sadly. T&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 12.800000190734863px;"&gt;his gives me correct data at the Part level view (the average of each part and then the sum of all), but at a Site level view this shows just the average (not what was displayed in the total column in the Part section of the drill-down).&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: 12.800000190734863px;"&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: 12.800000190734863px;"&gt;I have got close by using &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 12.800000190734863px;"&gt;sum(aggr(avg(Price),Part)), but this gives me odd results about 5% of the time. Sometimes the value display against the Site bears no resemblance to the data found by drilling down to Part. I can't work out why this is.&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 30 Jul 2014 07:47:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Nested-Aggregations-and-Drill-Down-Groups/m-p/675055#M475283</guid>
      <dc:creator>matthewjbryant</dc:creator>
      <dc:date>2014-07-30T07:47:21Z</dc:date>
    </item>
    <item>
      <title>Re: Nested Aggregations and Drill Down Groups</title>
      <link>https://community.qlik.com/t5/QlikView/Nested-Aggregations-and-Drill-Down-Groups/m-p/675056#M475284</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Matthew&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When you use aggr() in a chart, the dimensions in the aggr() statement need to include all the table/chart dimensions, so you might need something like:&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&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;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; sum(aggr(avg(Price),Part,Site)), &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&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;"&gt;(assuming Part and Site are the table dimensions)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&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;"&gt;HTH&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Jonathan&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 30 Jul 2014 07:51:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Nested-Aggregations-and-Drill-Down-Groups/m-p/675056#M475284</guid>
      <dc:creator>jonathandienst</dc:creator>
      <dc:date>2014-07-30T07:51:29Z</dc:date>
    </item>
    <item>
      <title>Re: Nested Aggregations and Drill Down Groups</title>
      <link>https://community.qlik.com/t5/QlikView/Nested-Aggregations-and-Drill-Down-Groups/m-p/675057#M475285</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Further analysis has proved that this doesn't solve the problem, sadly. When I compare &lt;STRONG&gt;sum(aggr(avg(Price),Part,Site))&lt;/STRONG&gt; at the Part level of the drill down with &lt;STRONG&gt;avg(Price)&lt;/STRONG&gt; on a table with just a Part dimension the values do not add up.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I need the price averaged at the Part level and that average summed at a Site level, but the aggr function is not averaging the values correctly with respect to Part as it stands.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The problem (or at least part of the problem) is that the aggr function is turning null values into 0. Why does it do this and is there a way of stopping it?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 31 Jul 2014 08:02:11 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Nested-Aggregations-and-Drill-Down-Groups/m-p/675057#M475285</guid>
      <dc:creator>matthewjbryant</dc:creator>
      <dc:date>2014-07-31T08:02:11Z</dc:date>
    </item>
    <item>
      <title>Re: Nested Aggregations and Drill Down Groups</title>
      <link>https://community.qlik.com/t5/QlikView/Nested-Aggregations-and-Drill-Down-Groups/m-p/675058#M475286</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Could you provide some data example in a qvw?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Ale&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 31 Jul 2014 11:56:13 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Nested-Aggregations-and-Drill-Down-Groups/m-p/675058#M475286</guid>
      <dc:creator>male_carrasco</dc:creator>
      <dc:date>2014-07-31T11:56:13Z</dc:date>
    </item>
  </channel>
</rss>

