<?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 Max function as variable in chart ignoring dimension in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Max-function-as-variable-in-chart-ignoring-dimension/m-p/1197439#M386082</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have a straight table where i have to show sum over a date range. The starting point of date is fixed (4th highest date) but end point variable. (like 7th or 10th highest date) depending on a field called SIT.&lt;/P&gt;&lt;P&gt;So, I store variable as vSIT = SIT&lt;/P&gt;&lt;P&gt;=sum({&amp;lt;W_Period={"&amp;gt;=$(=max(W_Period,$(=vSIT))))&amp;lt;$(=max(W_Period,4))"}&amp;gt;}WS_Qty)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My dimension is Country. If I use the above expression , if&amp;nbsp; I hard code then it is taking fine but when i pass variable it is taking maximum value of that field ignoring my country dimension. Please advice.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Country SIT&lt;/P&gt;&lt;P&gt;INDIA 16&lt;/P&gt;&lt;P&gt;INDONESIA 7&lt;/P&gt;&lt;P&gt;JAPAN 6&lt;/P&gt;&lt;P&gt;KOREA 6&lt;/P&gt;&lt;P&gt;MALAYSIA WEST 5&lt;/P&gt;&lt;P&gt;NEW ZEALAND 8&lt;/P&gt;&lt;P&gt;PHILIPPINES 5&lt;/P&gt;&lt;P&gt;TAIWAN 6&lt;/P&gt;&lt;P&gt;THAILAND 6&lt;/P&gt;&lt;P&gt;VIETNAM 7&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: Ruchi Bagaria&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 01 Oct 2016 15:42:16 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2016-10-01T15:42:16Z</dc:date>
    <item>
      <title>Max function as variable in chart ignoring dimension</title>
      <link>https://community.qlik.com/t5/QlikView/Max-function-as-variable-in-chart-ignoring-dimension/m-p/1197439#M386082</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have a straight table where i have to show sum over a date range. The starting point of date is fixed (4th highest date) but end point variable. (like 7th or 10th highest date) depending on a field called SIT.&lt;/P&gt;&lt;P&gt;So, I store variable as vSIT = SIT&lt;/P&gt;&lt;P&gt;=sum({&amp;lt;W_Period={"&amp;gt;=$(=max(W_Period,$(=vSIT))))&amp;lt;$(=max(W_Period,4))"}&amp;gt;}WS_Qty)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My dimension is Country. If I use the above expression , if&amp;nbsp; I hard code then it is taking fine but when i pass variable it is taking maximum value of that field ignoring my country dimension. Please advice.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Country SIT&lt;/P&gt;&lt;P&gt;INDIA 16&lt;/P&gt;&lt;P&gt;INDONESIA 7&lt;/P&gt;&lt;P&gt;JAPAN 6&lt;/P&gt;&lt;P&gt;KOREA 6&lt;/P&gt;&lt;P&gt;MALAYSIA WEST 5&lt;/P&gt;&lt;P&gt;NEW ZEALAND 8&lt;/P&gt;&lt;P&gt;PHILIPPINES 5&lt;/P&gt;&lt;P&gt;TAIWAN 6&lt;/P&gt;&lt;P&gt;THAILAND 6&lt;/P&gt;&lt;P&gt;VIETNAM 7&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: Ruchi Bagaria&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 01 Oct 2016 15:42:16 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Max-function-as-variable-in-chart-ignoring-dimension/m-p/1197439#M386082</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2016-10-01T15:42:16Z</dc:date>
    </item>
    <item>
      <title>Re: Max function as variable in chart ignoring dimension</title>
      <link>https://community.qlik.com/t5/QlikView/Max-function-as-variable-in-chart-ignoring-dimension/m-p/1197440#M386083</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Set analysis is evaluated once per chart. It will take just one value, like you have just discovered. You might need to use another approach to do this. Can you share a more comprehensive sample to be able to help you better&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 01 Oct 2016 15:44:17 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Max-function-as-variable-in-chart-ignoring-dimension/m-p/1197440#M386083</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2016-10-01T15:44:17Z</dc:date>
    </item>
    <item>
      <title>Re: Max function as variable in chart ignoring dimension</title>
      <link>https://community.qlik.com/t5/QlikView/Max-function-as-variable-in-chart-ignoring-dimension/m-p/1197441#M386084</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;That's how set analysis as well as dollar sign expansions work, they are evaluated once per chart, not per dimension line:&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.qlik.com/docs/DOC-1335"&gt;Evaluating "sets" in the context of a dimension&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 01 Oct 2016 15:45:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Max-function-as-variable-in-chart-ignoring-dimension/m-p/1197441#M386084</guid>
      <dc:creator>swuehl</dc:creator>
      <dc:date>2016-10-01T15:45:37Z</dc:date>
    </item>
    <item>
      <title>Re: Max function as variable in chart ignoring dimension</title>
      <link>https://community.qlik.com/t5/QlikView/Max-function-as-variable-in-chart-ignoring-dimension/m-p/1197442#M386085</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for the quick response. Please find the sample attahced. In this example, India total should be 500 and indonesia total should be 1150 but my expressions showing wrong values. please guide.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Ruchi ! !&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 01 Oct 2016 16:34:09 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Max-function-as-variable-in-chart-ignoring-dimension/m-p/1197442#M386085</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2016-10-01T16:34:09Z</dc:date>
    </item>
    <item>
      <title>Re: Max function as variable in chart ignoring dimension</title>
      <link>https://community.qlik.com/t5/QlikView/Max-function-as-variable-in-chart-ignoring-dimension/m-p/1197443#M386086</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Maybe like&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE bgcolor="#ffffff" border="1" cellpadding="2" cellspacing="0" style="font-size: 9pt;"&gt;&lt;TBODY&gt;&lt;TR bgcolor="#f5f5f5"&gt;&lt;TH nowrap="nowrap"&gt;&lt;SPAN style="color: #363636;"&gt;&lt;STRONG&gt;Market&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;STRONG&gt; &lt;/STRONG&gt;&lt;/TH&gt;&lt;TH nowrap="nowrap"&gt;&lt;SPAN style="color: #363636;"&gt;&lt;STRONG&gt;=sum( Aggr( If( Rank(Period) &amp;lt;= SIT and Rank(Period) &amp;gt; 4, Quantiy), Market,Period))&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;STRONG&gt; &lt;/STRONG&gt;&lt;/TH&gt;&lt;/TR&gt;&lt;TR bgcolor="#f5f5f5"&gt;&lt;TD bgcolor="#f5f5f5"&gt; &lt;/TD&gt;&lt;TD bgcolor="#f5f5f5"&gt;&lt;STRONG&gt;1650 &lt;/STRONG&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR bgcolor="#ffffff"&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;INDIA&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;500&lt;/SPAN&gt; &lt;/TD&gt;&lt;/TR&gt;&lt;TR bgcolor="#ffffff"&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;INDONESIA&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;1150&lt;/SPAN&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 01 Oct 2016 22:22:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Max-function-as-variable-in-chart-ignoring-dimension/m-p/1197443#M386086</guid>
      <dc:creator>swuehl</dc:creator>
      <dc:date>2016-10-01T22:22:57Z</dc:date>
    </item>
    <item>
      <title>Re: Max function as variable in chart ignoring dimension</title>
      <link>https://community.qlik.com/t5/QlikView/Max-function-as-variable-in-chart-ignoring-dimension/m-p/1197444#M386087</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you so much. I was so fretted about it. Such a neat solution!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 02 Oct 2016 05:42:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Max-function-as-variable-in-chart-ignoring-dimension/m-p/1197444#M386087</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2016-10-02T05:42:08Z</dc:date>
    </item>
  </channel>
</rss>

