<?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: How to calculate MAT when year as a dimension in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222849#M390763</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sunny,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If u dont mine can please explain the expression a bit clear&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;actually what happened is the expression is working very fine with my sample data&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But when i implemented the same expression in my original data&amp;nbsp; it is not working&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;even i tired step by step too&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;firstsortedvalue function is not working&amp;nbsp; in the original data&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;can u pls help me&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Hemanth&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 25 Jan 2017 06:05:30 GMT</pubDate>
    <dc:creator>hemanthaanichet</dc:creator>
    <dc:date>2017-01-25T06:05:30Z</dc:date>
    <item>
      <title>How to calculate MAT when year as a dimension</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222842#M390756</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Guys,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I need to calculate MAT for the available data&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="text-decoration: underline;"&gt;Moving Average Turnover (MAT):&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;Dimensions: &lt;/SPAN&gt;&lt;STRONG style="font-size: 10pt;"&gt;Year&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;Expression : &lt;STRONG&gt;(Current Year - Previous Year) / Previous Year&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;STRONG&gt;Current Year&lt;/STRONG&gt; : latest 12 months i.e.,&lt;STRONG&gt;(Aug-15 to Jul-16)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-size: 10pt;"&gt;Previous Year&lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt;"&gt; : previous latest 12 months i.e.,&lt;/SPAN&gt;&lt;STRONG style="font-size: 10pt;"&gt;(Aug-14 to Jul-15)&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;Expression &lt;/SPAN&gt;&lt;STRONG style="font-size: 10pt;"&gt;output value&lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt;"&gt; sholud be plotted in latest year i.e.,&lt;/SPAN&gt;&lt;STRONG style="font-size: 10pt;"&gt; 2016&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;Need to show all the&lt;/SPAN&gt;&lt;STRONG style="font-size: 10pt;"&gt; Year &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;STRONG style="text-decoration: underline;"&gt;Example 1:&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;STRONG&gt;Dimension&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Expression&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;STRONG&gt;2016&lt;/STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; (Current Year&lt;STRONG&gt; (Aug-15 to Jul-16)&lt;/STRONG&gt; - Previous Year &lt;STRONG&gt;(Aug-14 to Jul-15)&lt;/STRONG&gt;) / Previous Year &lt;STRONG&gt;(Aug-14 to Jul-15)&lt;/STRONG&gt;)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;STRONG&gt;2015&lt;/STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; (Current Year &lt;STRONG&gt;(Aug-14 to Jul-15)&lt;/STRONG&gt; - Previous Year &lt;STRONG&gt;(Aug-13 to Jul-14)&lt;/STRONG&gt;) / Previous Year &lt;STRONG&gt;(Aug-13 to Jul-14)&lt;/STRONG&gt;)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;sooo on for the remaining years&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;Month&lt;STRONG&gt; interval&lt;/STRONG&gt; has to vary based on the &lt;/SPAN&gt;selection&lt;SPAN style="font-size: 10pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;STRONG style="text-decoration: underline;"&gt;Exanple 2:&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-size: 10pt;"&gt;Selection&lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt;"&gt;: Year= &lt;/SPAN&gt;&lt;STRONG style="font-size: 10pt;"&gt;2016&lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt;"&gt; Month= &lt;/SPAN&gt;&lt;STRONG style="font-size: 10pt;"&gt;Apr&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-size: 10pt;"&gt;Dimension&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Expression&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;STRONG&gt;2016&amp;nbsp; &lt;/STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; (Current Year &lt;STRONG&gt;(May-15 to Apr-16)&lt;/STRONG&gt; - Previous Year &lt;STRONG&gt;(May-14 to Apr-15)&lt;/STRONG&gt;) / Previous Year &lt;STRONG&gt;(May-14 to Apr-15)&lt;/STRONG&gt;)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;STRONG&gt;2015&lt;/STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; (Current Year &lt;STRONG&gt;(May-14 to Apr-15)&lt;/STRONG&gt; - Previous Year &lt;STRONG&gt;(May-13 to Apr-14)&lt;/STRONG&gt;) / Previous Year &lt;STRONG&gt;(May-13 to Apr-14)&lt;/STRONG&gt;)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;sooo on for the remaining years&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;STRONG&gt;Selection&lt;/STRONG&gt;: Year= &lt;STRONG&gt;2015 &lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;STRONG&gt;Dimension&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Expression&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;STRONG&gt;2015&amp;nbsp; &lt;/STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; (Current Year&lt;STRONG&gt; (Jan-15 to Dec-15)&lt;/STRONG&gt; - Previous Year &lt;STRONG&gt;(Jan-14 to Dec-14)&lt;/STRONG&gt;) / Previous Year &lt;STRONG&gt;(Jan-14 to Dec-14)&lt;/STRONG&gt;)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;2014&amp;nbsp; &lt;/STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; (Current Year &lt;STRONG&gt;(Jan-14 to Dec-14)&lt;/STRONG&gt; - Previous Year &lt;STRONG&gt;(Jan-13 to Dec-13)&lt;/STRONG&gt;) / Previous Year &lt;STRONG&gt;(Jan-13 to Dec-13)&lt;/STRONG&gt;)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;sooo on for the remaining years&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Attached the same data&lt;SPAN style="font-size: 10pt;"&gt; &lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 24 Jan 2017 04:36:54 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222842#M390756</guid>
      <dc:creator>hemanthaanichet</dc:creator>
      <dc:date>2017-01-24T04:36:54Z</dc:date>
    </item>
    <item>
      <title>Re: How to calculate MAT when year as a dimension</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222843#M390757</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Sorry Guys&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I attached a worng QVW&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Pls have a look on the corrected attachment below&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Hemanth&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 24 Jan 2017 04:41:32 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222843#M390757</guid>
      <dc:creator>hemanthaanichet</dc:creator>
      <dc:date>2017-01-24T04:41:32Z</dc:date>
    </item>
    <item>
      <title>Re: How to calculate MAT when year as a dimension</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222844#M390758</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;May be this?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;FirstSortedValue({&amp;lt;MonthNum = {$(=Max({&amp;lt;Year = {$(=Max(Year))}&amp;gt;}MonthNum))}&amp;gt;}Aggr(RangeSum(Above(Sum(Sales), 0, 12)), YearMonth), -YearMonth)&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;/&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Above(FirstSortedValue({&amp;lt;MonthNum = {$(=Max({&amp;lt;Year = {$(=Max(Year))}&amp;gt;}MonthNum))}&amp;gt;}Aggr(RangeSum(Above(Sum(Sales), 0, 12)), YearMonth), -YearMonth))-1&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Capture.PNG" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/150649_Capture.PNG" style="height: 429px; width: 620px;" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 24 Jan 2017 10:43:31 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222844#M390758</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2017-01-24T10:43:31Z</dc:date>
    </item>
    <item>
      <title>Re: How to calculate MAT when year as a dimension</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222845#M390759</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sunny,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Exactly the same answer which i required.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But still one more required when i select the year the data is not displayed in the chart&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;please sort out this one&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 24 Jan 2017 11:23:19 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222845#M390759</guid>
      <dc:creator>hemanthaanichet</dc:creator>
      <dc:date>2017-01-24T11:23:19Z</dc:date>
    </item>
    <item>
      <title>Re: How to calculate MAT when year as a dimension</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222846#M390760</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Ignore selection in Year field my friend. Have you not looked at set analysis guide yet? Highly recommend spending some time with it &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt; -&amp;gt; &lt;A href="https://community.qlik.com/docs/DOC-4951"&gt;Set Analysis: syntaxes, examples&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;FirstSortedValue({&amp;lt;MonthNum = {$(=Max({&amp;lt;Year = {$(=Max(Year))}&amp;gt;}MonthNum))}, Year&amp;gt;}Aggr(RangeSum(Above(Sum({&amp;lt;Year&amp;gt;}Sales), 0, 12)), YearMonth), -YearMonth)&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;/&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Above(FirstSortedValue({&amp;lt;MonthNum = {$(=Max({&amp;lt;Year = {$(=Max(Year))}&amp;gt;}MonthNum))}, Year&amp;gt;}Aggr(RangeSum(Above(Sum({&amp;lt;Year&amp;gt;}Sales), 0, 12)), YearMonth), -YearMonth))-1&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 24 Jan 2017 12:06:31 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222846#M390760</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2017-01-24T12:06:31Z</dc:date>
    </item>
    <item>
      <title>Re: How to calculate MAT when year as a dimension</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222847#M390761</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Oops i forget it&lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/plain.png" /&gt;, Highly stressed in mind might forget small small things&lt;/P&gt;&lt;P&gt;But these forget things can be over come when there is a friend like you.&lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers....! &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 24 Jan 2017 12:18:17 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222847#M390761</guid>
      <dc:creator>hemanthaanichet</dc:creator>
      <dc:date>2017-01-24T12:18:17Z</dc:date>
    </item>
    <item>
      <title>Re: How to calculate MAT when year as a dimension</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222848#M390762</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You got it brother &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 24 Jan 2017 12:19:31 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222848#M390762</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2017-01-24T12:19:31Z</dc:date>
    </item>
    <item>
      <title>Re: How to calculate MAT when year as a dimension</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222849#M390763</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sunny,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If u dont mine can please explain the expression a bit clear&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;actually what happened is the expression is working very fine with my sample data&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But when i implemented the same expression in my original data&amp;nbsp; it is not working&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;even i tired step by step too&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;firstsortedvalue function is not working&amp;nbsp; in the original data&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;can u pls help me&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Hemanth&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 Jan 2017 06:05:30 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222849#M390763</guid>
      <dc:creator>hemanthaanichet</dc:creator>
      <dc:date>2017-01-25T06:05:30Z</dc:date>
    </item>
    <item>
      <title>Re: How to calculate MAT when year as a dimension</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222850#M390764</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sunny,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Actually what is issue is&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In the sample data , For one month there is only one value &lt;/P&gt;&lt;P&gt;ex: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;YearMonth&amp;nbsp;&amp;nbsp;&amp;nbsp; Sale&lt;/P&gt;&lt;P&gt;Apr-16&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 201&lt;/P&gt;&lt;P&gt;May-16&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 301&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But I my actual data, for one month there are so many values&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Ex:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Yearmonth&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Sale &lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;Apr-16&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 201&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;Apr-16&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 202&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;Apr-16&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 203&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;Apr-16&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 204&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;May-16&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 301&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;May-16&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 302&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;May-16&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 303&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;May-16&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 304&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;May-16&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 305&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;i think because of this the firstsortedvalue function hasnt work &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;is there any other suggestion to overcome this issue&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;Regards&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;Hemanth&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 Jan 2017 11:21:09 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222850#M390764</guid>
      <dc:creator>hemanthaanichet</dc:creator>
      <dc:date>2017-01-25T11:21:09Z</dc:date>
    </item>
    <item>
      <title>Re: How to calculate MAT when year as a dimension</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222851#M390765</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Would you be able to update the sample and show me the issue?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 Jan 2017 11:57:36 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222851#M390765</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2017-01-25T11:57:36Z</dc:date>
    </item>
    <item>
      <title>Re: How to calculate MAT when year as a dimension</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222852#M390766</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sunny,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Attached the sample data with few updates&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 Jan 2017 12:04:19 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222852#M390766</guid>
      <dc:creator>hemanthaanichet</dc:creator>
      <dc:date>2017-01-25T12:04:19Z</dc:date>
    </item>
    <item>
      <title>Re: How to calculate MAT when year as a dimension</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222853#M390767</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Try this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;FirstSortedValue({&amp;lt;MonthNum = {$(=Max({&amp;lt;Year = {$(=Max(Year))}&amp;gt;}MonthNum))}, Year&amp;gt;}Aggr(RangeSum(Above(Sum({&amp;lt;Year&amp;gt;}Sales), 0, 12)), YearMonth), -Aggr(Only({&amp;lt;Year&amp;gt;}YearMonth), YearMonth))&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;/&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Above(FirstSortedValue({&amp;lt;MonthNum = {$(=Max({&amp;lt;Year = {$(=Max(Year))}&amp;gt;}MonthNum))}, Year&amp;gt;}Aggr(RangeSum(Above(Sum({&amp;lt;Year&amp;gt;}Sales), 0, 12)), YearMonth), -Aggr(Only({&amp;lt;Year&amp;gt;}YearMonth), YearMonth)))-1&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 Jan 2017 12:10:06 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222853#M390767</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2017-01-25T12:10:06Z</dc:date>
    </item>
    <item>
      <title>Re: How to calculate MAT when year as a dimension</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222854#M390768</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sunny,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Your Expression works fine in the sample data&lt;/P&gt;&lt;P&gt;but i implemented in my original data values are not correct&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 Jan 2017 12:39:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222854#M390768</guid>
      <dc:creator>hemanthaanichet</dc:creator>
      <dc:date>2017-01-25T12:39:01Z</dc:date>
    </item>
    <item>
      <title>Re: How to calculate MAT when year as a dimension</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222855#M390769</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;What's the difference? Do you know &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt; I def. have no idea&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 Jan 2017 12:40:17 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222855#M390769</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2017-01-25T12:40:17Z</dc:date>
    </item>
    <item>
      <title>Re: How to calculate MAT when year as a dimension</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222856#M390770</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sunny,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Output Values are not matching when checked manually&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;when in expression&amp;nbsp; output values&lt;/P&gt;&lt;P&gt;i.e.,&lt;/P&gt;&lt;P&gt;2013 = ((Sep-12 to Aug-13) - (Sep-11 to&amp;nbsp; Aug-12)) /&amp;nbsp; &lt;SPAN style="font-size: 13.3333px;"&gt;(Sep-11 to&amp;nbsp; Aug-12)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;2014 = ((Sep-13 to Aug-14) - (Sep-12 to&amp;nbsp; Aug-13)) /&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;(Sep-12 to&amp;nbsp; Aug-13)&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;2015 = ((Sep-14 to Aug-15) - (Sep-13 to&amp;nbsp; Aug-14)) /&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;(Sep-13 to&amp;nbsp; Aug-14)&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;2016 = ((Sep-15 to Aug-16) - (Sep-14 to&amp;nbsp; Aug-15)) /&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;(Sep-14 to&amp;nbsp; Aug-15)&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG __jive_id="150940" alt="5.PNG" class="jive-image image-3" src="https://community.qlik.com/legacyfs/online/150940_5.PNG" style="height: auto;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;when i checked manually the output values&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;i.e., &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;2013 = ((Sep-12 to Aug-13) - (Sep-11 to&amp;nbsp; Aug-12)) /&amp;nbsp; &lt;SPAN style="font-size: 13.3333px;"&gt;(Sep-11 to&amp;nbsp; Aug-12)&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;2014 = ((Sep-13 to Aug-14) - (Sep-12 to&amp;nbsp; Aug-13)) /&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;(Sep-12 to&amp;nbsp; Aug-13)&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;2015 = ((Sep-14 to Aug-15) - (Sep-13 to&amp;nbsp; Aug-14)) /&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;(Sep-13 to&amp;nbsp; Aug-14)&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;2016 = ((Sep-15 to Aug-16) - (Sep-14 to&amp;nbsp; Aug-15)) /&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;(Sep-14 to&amp;nbsp; Aug-15)&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG __jive_id="150939" alt="6.PNG" class="jive-image image-2" src="https://community.qlik.com/legacyfs/online/150939_6.PNG" style="height: auto;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Below link contains th Original Data&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt; &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;QVD Link&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://drive.google.com/file/d/0B3Gty6OdUAqVNU5IN2ttWXNDbE0/view?usp=sharing" title="https://drive.google.com/file/d/0B3Gty6OdUAqVNU5IN2ttWXNDbE0/view?usp=sharing"&gt;Sample.qvd - Google Drive&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;QVW Link&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://drive.google.com/file/d/0B3Gty6OdUAqVYzJfVmgtSE1iT0E/view?usp=sharing" title="https://drive.google.com/file/d/0B3Gty6OdUAqVYzJfVmgtSE1iT0E/view?usp=sharing"&gt;Sample.qvw - Google Drive&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 26 Jan 2017 08:24:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222856#M390770</guid>
      <dc:creator>hemanthaanichet</dc:creator>
      <dc:date>2017-01-26T08:24:20Z</dc:date>
    </item>
    <item>
      <title>Re: How to calculate MAT when year as a dimension</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222857#M390771</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sunny,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This mis matching is because of aggr, is there any&amp;nbsp; other way we can solve without using Aggr&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 27 Jan 2017 05:31:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222857#M390771</guid>
      <dc:creator>hemanthaanichet</dc:creator>
      <dc:date>2017-01-27T05:31:08Z</dc:date>
    </item>
    <item>
      <title>Re: How to calculate MAT when year as a dimension</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222858#M390772</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You need to fix your load order (or not if you are using QV12).... I assumed that you don't have QV 12 and since you shared the qvw,have fixed the load order in the script like this&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Table:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;LOAD date(date#(DATAPERIOD,'YYYYMM'),'YYYYMM') AS Period,&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; NVALUE as Sales&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;FROM&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;[Sample.qvd]&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;(qvd);&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Calendar:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;LOAD DISTINCT Period,&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Year(Period) AS Year,&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Num(Month(Period)) AS MonthNum,&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Month(Period) AS Month,&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Date(MonthStart(Period),'MMM-YY') as YearMonth&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Resident Table&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Order By Period;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Basically, you need to load the YearMonth field in ascending order for the expression to work properly. Since you cannot use Order by in a qvd load, I created another table called Calendar which is basically loaded ordering by Period field.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Once I did this, the expression just needed to ignore selection in Month field and it worked&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;FirstSortedValue({&amp;lt;MonthNum = {$(=Max({&amp;lt;Year = {$(=Max(Year))}&amp;gt;}MonthNum))}, Year&lt;SPAN style="color: #ff0000;"&gt;, Month&lt;/SPAN&gt;&amp;gt;}Aggr(RangeSum(Above(Sum({&amp;lt;Year&lt;STRONG style="color: #ff0000; font-size: 13.3333px;"&gt;, Month&lt;/STRONG&gt;&amp;gt;}Sales), 0, 12)), YearMonth), -Aggr(Only({&amp;lt;Year&lt;STRONG style="color: #ff0000; font-size: 13.3333px;"&gt;, Month&lt;/STRONG&gt;&amp;gt;}YearMonth), YearMonth))&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;/&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Above(FirstSortedValue({&amp;lt;MonthNum = {$(=Max({&amp;lt;Year = {$(=Max(Year))}&amp;gt;}MonthNum))}, Year&lt;STRONG style="color: #ff0000; font-size: 13.3333px;"&gt;, Month&lt;/STRONG&gt;&amp;gt;}Aggr(RangeSum(Above(Sum({&amp;lt;Year&lt;STRONG style="color: #ff0000; font-size: 13.3333px;"&gt;, Month&lt;/STRONG&gt;&amp;gt;}Sales), 0, 12)), YearMonth), -Aggr(Only({&amp;lt;Year&lt;STRONG style="color: #ff0000; font-size: 13.3333px;"&gt;, Month&lt;/STRONG&gt;&amp;gt;}YearMonth), YearMonth)))-1&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Capture.PNG" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/151121_Capture.PNG" style="height: auto;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Finally, apologize for a late response, just wasn't getting enough time to work on this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best,&lt;/P&gt;&lt;P&gt;Sunny&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 28 Jan 2017 21:41:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222858#M390772</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2017-01-28T21:41:22Z</dc:date>
    </item>
    <item>
      <title>Re: How to calculate MAT when year as a dimension</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222859#M390773</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Sunny..&lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you very much. it working sunny once again than you very much&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;one clarification if i select year= 2014 the values are showing from 2015 &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;is this because of our functionality of expression?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 29 Jan 2017 08:09:50 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222859#M390773</guid>
      <dc:creator>hemanthaanichet</dc:creator>
      <dc:date>2017-01-29T08:09:50Z</dc:date>
    </item>
    <item>
      <title>Re: How to calculate MAT when year as a dimension</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222860#M390774</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You want to see less then the years selected? May be try this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;FirstSortedValue({&amp;lt;MonthNum = {$(=Max({&amp;lt;Year = {$(=Max(Year))}&amp;gt;}MonthNum))}, Year &lt;SPAN style="color: #ff0000;"&gt;= {"$(='&amp;lt;=' &amp;amp; Max(Year))"}&lt;/SPAN&gt;, Month&amp;gt;}Aggr(RangeSum(Above(Sum({&amp;lt;Year, Month&amp;gt;}Sales), 0, 12)), YearMonth), -Aggr(Only({&amp;lt;Year, Month&amp;gt;}YearMonth), YearMonth))&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;/&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Above(FirstSortedValue({&amp;lt;MonthNum = {$(=Max({&amp;lt;Year = {$(=Max(Year))}&amp;gt;}MonthNum))}, Year, Month&amp;gt;}Aggr(RangeSum(Above(Sum({&amp;lt;Year, Month&amp;gt;}Sales), 0, 12)), YearMonth), -Aggr(Only({&amp;lt;Year, Month&amp;gt;}YearMonth), YearMonth)))-1&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Capture.PNG" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/151140_Capture.PNG" style="height: 187px; width: 620px;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Capture.PNG" class="jive-image image-2" src="https://community.qlik.com/legacyfs/online/151141_Capture.PNG" style="height: 177px; width: 620px;" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 29 Jan 2017 12:16:06 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222860#M390774</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2017-01-29T12:16:06Z</dc:date>
    </item>
    <item>
      <title>Re: How to calculate MAT when year as a dimension</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222861#M390775</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you Sunny..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Feeling very happy...&lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt;&lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt;&lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if&amp;nbsp; u dnt mine if u have any QMC related doc pls can u share...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers....!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 30 Jan 2017 10:22:06 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-calculate-MAT-when-year-as-a-dimension/m-p/1222861#M390775</guid>
      <dc:creator>hemanthaanichet</dc:creator>
      <dc:date>2017-01-30T10:22:06Z</dc:date>
    </item>
  </channel>
</rss>

