<?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 Pivot table with averages - problem with the total in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Pivot-table-with-averages-problem-with-the-total/m-p/276518#M495358</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have a Pivot table with 4 dimensions:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Product (Row)&lt;/P&gt;&lt;P&gt;Branch (Row)&lt;/P&gt;&lt;P&gt;SalesMonth (Column)&lt;/P&gt;&lt;P&gt;Stage (Column)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and 1 expression&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sum(Average) as Average&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The aim is to show the average length of time it takes for a Product to pass through each stage from Sale to Installation depending on when the Sale was made. For example a sale made in Branch 1 for Product 1 in Month 1 takes 50 days whereas if the sale was made in Month 2 it takes 60 days to install.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The Average length of time in each stage is calculated within the loader script by SalesMonth, Branch and Product.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When Product and Branch are expanded the chart is fine but they also want to see the overall average for each product across all of the branches - this bit doesn't work as it just gives a TOTAL of all of the Averages. What I need is an AVERAGE of all of the Averages.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I can't really give an example due to the sensitivity of the data but if you need any more information I'll try my best.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 13 Feb 2012 11:31:50 GMT</pubDate>
    <dc:creator />
    <dc:date>2012-02-13T11:31:50Z</dc:date>
    <item>
      <title>Pivot table with averages - problem with the total</title>
      <link>https://community.qlik.com/t5/QlikView/Pivot-table-with-averages-problem-with-the-total/m-p/276518#M495358</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have a Pivot table with 4 dimensions:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Product (Row)&lt;/P&gt;&lt;P&gt;Branch (Row)&lt;/P&gt;&lt;P&gt;SalesMonth (Column)&lt;/P&gt;&lt;P&gt;Stage (Column)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and 1 expression&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sum(Average) as Average&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The aim is to show the average length of time it takes for a Product to pass through each stage from Sale to Installation depending on when the Sale was made. For example a sale made in Branch 1 for Product 1 in Month 1 takes 50 days whereas if the sale was made in Month 2 it takes 60 days to install.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The Average length of time in each stage is calculated within the loader script by SalesMonth, Branch and Product.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When Product and Branch are expanded the chart is fine but they also want to see the overall average for each product across all of the branches - this bit doesn't work as it just gives a TOTAL of all of the Averages. What I need is an AVERAGE of all of the Averages.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I can't really give an example due to the sensitivity of the data but if you need any more information I'll try my best.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 13 Feb 2012 11:31:50 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Pivot-table-with-averages-problem-with-the-total/m-p/276518#M495358</guid>
      <dc:creator />
      <dc:date>2012-02-13T11:31:50Z</dc:date>
    </item>
    <item>
      <title>Pivot table with averages - problem with the total</title>
      <link>https://community.qlik.com/t5/QlikView/Pivot-table-with-averages-problem-with-the-total/m-p/276519#M495359</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;sum(Average) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;is your expression? Not sure if I would sum averages, but you will know.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You could try using advanved aggregation to get an average of your table values instead of an expression total.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=avg( aggr( sum(Average) , Product,Branch,SalesMonth, Stage))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please check the Help for some information about using aggr() function in the context of sum-of-rows (which in your case would be better called avg-of-rows).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If the level of aggregation is not correct, you could probably succeed with adding a total qualifier or refining the aggr() dimension list / using two embedded aggr() functions. If you are running into problems, could you post some mockup data together with your required table outcome?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps,&lt;/P&gt;&lt;P&gt;Stefan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 13 Feb 2012 12:05:46 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Pivot-table-with-averages-problem-with-the-total/m-p/276519#M495359</guid>
      <dc:creator>swuehl</dc:creator>
      <dc:date>2012-02-13T12:05:46Z</dc:date>
    </item>
    <item>
      <title>Pivot table with averages - problem with the total</title>
      <link>https://community.qlik.com/t5/QlikView/Pivot-table-with-averages-problem-with-the-total/m-p/276520#M495360</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank-you that was absolutely spot on. I was considering doing 2 charts. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I've never had to really use aggr before now but this works so really pleased.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 13 Feb 2012 12:18:17 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Pivot-table-with-averages-problem-with-the-total/m-p/276520#M495360</guid>
      <dc:creator />
      <dc:date>2012-02-13T12:18:17Z</dc:date>
    </item>
  </channel>
</rss>

