<?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: Aggregation pivot calculation in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Aggregation-pivot-calculation/m-p/1640484#M47739</link>
    <description>&lt;P&gt;Have you tried the expression I post before?:&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Sum(Aggr(&lt;/SPAN&gt;&lt;SPAN&gt;Portion*Amount, Article, Ingredient, Portion))&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;or:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Sum(Aggr(Sum(Portion)*Amount, Article, Ingredient, Portion))&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Mon, 28 Oct 2019 16:39:47 GMT</pubDate>
    <dc:creator>rubenmarin</dc:creator>
    <dc:date>2019-10-28T16:39:47Z</dc:date>
    <item>
      <title>Aggregation pivot calculation</title>
      <link>https://community.qlik.com/t5/App-Development/Aggregation-pivot-calculation/m-p/1640296#M47716</link>
      <description>&lt;P&gt;Good morning,&lt;/P&gt;&lt;P&gt;I've this table below. The portion refers to the batch amount per article. If I multiply the portion by the amount per portion produced, I get the overall amount (dimension Portion*Amount). The PortionAmount is a master measure with the same formula (with the benefit that I can add an aggregation function from the list). I can't use this master measure in my pivot table (on another sheet). If I aggregate this with SUM, the total is very different. The total amount in "PortionAmount", the master measure is the right (total) amount. Why are these two totals different?&lt;/P&gt;&lt;P&gt;How can I get an aggregation with the right total amount, which works in a pivot table as a measure?&lt;/P&gt;&lt;P&gt;Thanks in advance&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Table" style="width: 999px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/22431i1C7AF349A3BDE625/image-size/large?v=v2&amp;amp;px=999" role="button" title="Aggr Amount Portion.PNG" alt="Table" /&gt;&lt;span class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;Table&lt;/span&gt;&lt;/span&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Master measure" style="width: 481px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/22432iB0500C111D689E44/image-size/large?v=v2&amp;amp;px=999" role="button" title="Aggr master measure.PNG" alt="Master measure" /&gt;&lt;span class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;Master measure&lt;/span&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 16 Nov 2024 04:15:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Aggregation-pivot-calculation/m-p/1640296#M47716</guid>
      <dc:creator>Bart_Breekveldt</dc:creator>
      <dc:date>2024-11-16T04:15:34Z</dc:date>
    </item>
    <item>
      <title>Re: Aggregation pivot calculation</title>
      <link>https://community.qlik.com/t5/App-Development/Aggregation-pivot-calculation/m-p/1640307#M47718</link>
      <description>&lt;P&gt;hi, it looks like each table row has manny records associated, 35700/105 is 340, so 340 rows with the same numbers are counted in the sum.&lt;/P&gt;&lt;P&gt;This is probably an issue in how is created the data model (just probably).&lt;/P&gt;&lt;P&gt;To get the expected total maybe with Sum(Aggr(&lt;SPAN&gt;Portion*Amount, Article, Ingredient, Portion))&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 28 Oct 2019 11:23:05 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Aggregation-pivot-calculation/m-p/1640307#M47718</guid>
      <dc:creator>rubenmarin</dc:creator>
      <dc:date>2019-10-28T11:23:05Z</dc:date>
    </item>
    <item>
      <title>Re: Aggregation pivot calculation</title>
      <link>https://community.qlik.com/t5/App-Development/Aggregation-pivot-calculation/m-p/1640443#M47736</link>
      <description>&lt;P&gt;Thanks for the tip, it was indeed that portion (batch size) should not be summed. But the formula didn't work. I found the function 'Only', which is an aggregation function. I'm now at:&amp;nbsp;SUM(Amount)*Only(Portion). It don't add up if I remove the Portion dimension because of the Only function. How can I turn this Only function in my Sum function to fix this problem?&lt;/P&gt;</description>
      <pubDate>Mon, 28 Oct 2019 15:35:00 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Aggregation-pivot-calculation/m-p/1640443#M47736</guid>
      <dc:creator>Bart_Breekveldt</dc:creator>
      <dc:date>2019-10-28T15:35:00Z</dc:date>
    </item>
    <item>
      <title>Re: Aggregation pivot calculation</title>
      <link>https://community.qlik.com/t5/App-Development/Aggregation-pivot-calculation/m-p/1640484#M47739</link>
      <description>&lt;P&gt;Have you tried the expression I post before?:&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Sum(Aggr(&lt;/SPAN&gt;&lt;SPAN&gt;Portion*Amount, Article, Ingredient, Portion))&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;or:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Sum(Aggr(Sum(Portion)*Amount, Article, Ingredient, Portion))&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 28 Oct 2019 16:39:47 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Aggregation-pivot-calculation/m-p/1640484#M47739</guid>
      <dc:creator>rubenmarin</dc:creator>
      <dc:date>2019-10-28T16:39:47Z</dc:date>
    </item>
  </channel>
</rss>

