<?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: Roll Up Totals in Chart Based on Multiple Selected Values in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Roll-Up-Totals-in-Chart-Based-on-Multiple-Selected-Values/m-p/1927372#M1218851</link>
    <description>&lt;P&gt;Fixed it!&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;= IF( AGGR(RANK(SUM(Sales)), Customer) &amp;lt;= 10
	, AGGR(SUM(Sales), Customer)
	, Null()
)
&lt;/LI-CODE&gt;</description>
    <pubDate>Fri, 06 May 2022 13:52:05 GMT</pubDate>
    <dc:creator>Kodafixed</dc:creator>
    <dc:date>2022-05-06T13:52:05Z</dc:date>
    <item>
      <title>Roll Up Totals in Chart Based on Multiple Selected Values</title>
      <link>https://community.qlik.com/t5/QlikView/Roll-Up-Totals-in-Chart-Based-on-Multiple-Selected-Values/m-p/1926416#M1218795</link>
      <description>&lt;P&gt;I have a BI dashboard that needs to show the Top 10 performing customers based on the viewer's selection of date(s) and area(s). The underlying table data stores the Sales Period (YYYY-MM), Sales Area, Customer Name, and the total invoiced revenue from them for that period.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;ExampleData:
LOAD INLINE [
Period|Area|Customer|Sales
2021-01|North|ABC Corp|1,000,000
2021-02|North|XYZ Co|1,500,000
2021-01|South|ABC Corp|2,000,000
2021-02|North|XYZ Co|950,000
...
] (DELIMITER IS '|');&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In my straight table chart I have a calculated field to get the top-10 customers by sales and it seems to work if the user selects at least 1 and only 1 of either|both Period &amp;amp; Area, but if they select multiples of either or select none of either it breaks.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;= MONEY(
    AGGR( IF( RANK(TOTAL SUM({&amp;lt;[Customer Name]&amp;gt;} [Customer Sales])) &amp;lt;= 10, [Customer Sales]), [Customer Sales])
    , '$ #,##0'
)
&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;What I am needing the chart to do is, if the user selects multiple Periods &amp;amp;/or Areas, or none of either, that the top-10 returned is the "aggregate" sum of all Periods/Dates in the current selection as a single entry.&lt;/P&gt;
&lt;P&gt;I've been googling and reading solutions for the last day and none of what I'm finding addresses this issue. Thanks in advance!&lt;/P&gt;</description>
      <pubDate>Wed, 04 May 2022 15:49:39 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Roll-Up-Totals-in-Chart-Based-on-Multiple-Selected-Values/m-p/1926416#M1218795</guid>
      <dc:creator>Kodafixed</dc:creator>
      <dc:date>2022-05-04T15:49:39Z</dc:date>
    </item>
    <item>
      <title>Re: Roll Up Totals in Chart Based on Multiple Selected Values</title>
      <link>https://community.qlik.com/t5/QlikView/Roll-Up-Totals-in-Chart-Based-on-Multiple-Selected-Values/m-p/1927372#M1218851</link>
      <description>&lt;P&gt;Fixed it!&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;= IF( AGGR(RANK(SUM(Sales)), Customer) &amp;lt;= 10
	, AGGR(SUM(Sales), Customer)
	, Null()
)
&lt;/LI-CODE&gt;</description>
      <pubDate>Fri, 06 May 2022 13:52:05 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Roll-Up-Totals-in-Chart-Based-on-Multiple-Selected-Values/m-p/1927372#M1218851</guid>
      <dc:creator>Kodafixed</dc:creator>
      <dc:date>2022-05-06T13:52:05Z</dc:date>
    </item>
  </channel>
</rss>

