<?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: Last 3 Years in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Last-3-Years/m-p/638176#M476380</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;See attached, I just used =if(currentyr - fyear &amp;lt;= 3, Record) as the expression for the list box.&amp;nbsp; Hope this helps!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 03 Jun 2014 20:34:08 GMT</pubDate>
    <dc:creator />
    <dc:date>2014-06-03T20:34:08Z</dc:date>
    <item>
      <title>Last 3 Years</title>
      <link>https://community.qlik.com/t5/QlikView/Last-3-Years/m-p/638174#M476378</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I need to show only last 3 years in a listbox from the table below. Can someone tell me if I am writing this function correctly? Thanks so much in advance!!!! See the table below:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;= &lt;SPAN style="font-size: 8pt;"&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;if&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;fyear&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;currentyr&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;, &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;if&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;fyear&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;currentyr&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;-1, &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;if&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;fyear&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;currentyr&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;-2, &lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;fyear&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;))) &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;In Expressions box, this function shows no error but I don't see this working or showing only 2014, 2013, 2013 in the listbox.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE border="0" cellpadding="0" cellspacing="0" width="190"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD class="xl64" height="20" width="64"&gt; &lt;/TD&gt;&lt;TD class="xl65" style="border-left: medium none;" width="63"&gt;fyear&lt;/TD&gt;&lt;TD class="xl65" style="border-left: medium none;" width="63"&gt;currentyr&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: medium none;"&gt;Record 1&lt;/TD&gt;&lt;TD align="right" class="xl66" style="border-left: medium none; border-top: medium none;"&gt;2009&lt;/TD&gt;&lt;TD align="right" class="xl66" style="border-left: medium none; border-top: medium none;"&gt;2014&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: medium none;"&gt;Record 2&lt;/TD&gt;&lt;TD align="right" class="xl66" style="border-left: medium none; border-top: medium none;"&gt;2009&lt;/TD&gt;&lt;TD align="right" class="xl66" style="border-left: medium none; border-top: medium none;"&gt;2014&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: medium none;"&gt;Record 3&lt;/TD&gt;&lt;TD align="right" class="xl66" style="border-left: medium none; border-top: medium none;"&gt;2010&lt;/TD&gt;&lt;TD align="right" class="xl66" style="border-left: medium none; border-top: medium none;"&gt;2014&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: medium none;"&gt;Record 4&lt;/TD&gt;&lt;TD align="right" class="xl66" style="border-left: medium none; border-top: medium none;"&gt;2010&lt;/TD&gt;&lt;TD align="right" class="xl66" style="border-left: medium none; border-top: medium none;"&gt;2014&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: medium none;"&gt;Record 5&lt;/TD&gt;&lt;TD align="right" class="xl66" style="border-left: medium none; border-top: medium none;"&gt;2011&lt;/TD&gt;&lt;TD align="right" class="xl66" style="border-left: medium none; border-top: medium none;"&gt;2014&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: medium none;"&gt;Record 6&lt;/TD&gt;&lt;TD align="right" class="xl66" style="border-left: medium none; border-top: medium none;"&gt;2012&lt;/TD&gt;&lt;TD align="right" class="xl66" style="border-left: medium none; border-top: medium none;"&gt;2014&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: medium none;"&gt;Record 7&lt;/TD&gt;&lt;TD align="right" class="xl66" style="border-left: medium none; border-top: medium none;"&gt;2011&lt;/TD&gt;&lt;TD align="right" class="xl66" style="border-left: medium none; border-top: medium none;"&gt;2014&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: medium none;"&gt;Record 8&lt;/TD&gt;&lt;TD align="right" class="xl66" style="border-left: medium none; border-top: medium none;"&gt;2012&lt;/TD&gt;&lt;TD align="right" class="xl66" style="border-left: medium none; border-top: medium none;"&gt;2014&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: medium none;"&gt;Record 9&lt;/TD&gt;&lt;TD align="right" class="xl66" style="border-left: medium none; border-top: medium none;"&gt;2013&lt;/TD&gt;&lt;TD align="right" class="xl66" style="border-left: medium none; border-top: medium none;"&gt;2014&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: medium none;"&gt;Record 10&lt;/TD&gt;&lt;TD align="right" class="xl66" style="border-left: medium none; border-top: medium none;"&gt;2013&lt;/TD&gt;&lt;TD align="right" class="xl66" style="border-left: medium none; border-top: medium none;"&gt;2014&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: medium none;"&gt;Record 11&lt;/TD&gt;&lt;TD align="right" class="xl66" style="border-left: medium none; border-top: medium none;"&gt;2014&lt;/TD&gt;&lt;TD align="right" class="xl66" style="border-left: medium none; border-top: medium none;"&gt;2014&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: medium none;"&gt;Record 12&lt;/TD&gt;&lt;TD align="right" class="xl66" style="border-left: medium none; border-top: medium none;"&gt;2014&lt;/TD&gt;&lt;TD align="right" class="xl66" style="border-left: medium none; border-top: medium none;"&gt;2014&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: medium none;"&gt;Record 13&lt;/TD&gt;&lt;TD align="right" class="xl66" style="border-left: medium none; border-top: medium none;"&gt;2014&lt;/TD&gt;&lt;TD align="right" class="xl66" style="border-left: medium none; border-top: medium none;"&gt;2014&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;BR /&gt; &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 03 Jun 2014 20:26:50 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Last-3-Years/m-p/638174#M476378</guid>
      <dc:creator />
      <dc:date>2014-06-03T20:26:50Z</dc:date>
    </item>
    <item>
      <title>Re: Last 3 Years</title>
      <link>https://community.qlik.com/t5/QlikView/Last-3-Years/m-p/638175#M476379</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Try using calculated dimension instead of Record (assuming the filed name is Record):&lt;/P&gt;&lt;P&gt;aggr(if(fyear&amp;gt;=(currentyr-2), Record), Record)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 03 Jun 2014 20:33:32 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Last-3-Years/m-p/638175#M476379</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-06-03T20:33:32Z</dc:date>
    </item>
    <item>
      <title>Re: Last 3 Years</title>
      <link>https://community.qlik.com/t5/QlikView/Last-3-Years/m-p/638176#M476380</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;See attached, I just used =if(currentyr - fyear &amp;lt;= 3, Record) as the expression for the list box.&amp;nbsp; Hope this helps!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 03 Jun 2014 20:34:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Last-3-Years/m-p/638176#M476380</guid>
      <dc:creator />
      <dc:date>2014-06-03T20:34:08Z</dc:date>
    </item>
    <item>
      <title>Re: Last 3 Years</title>
      <link>https://community.qlik.com/t5/QlikView/Last-3-Years/m-p/638177#M476381</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;This one totally works!!! Thanks!!!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 03 Jun 2014 20:38:43 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Last-3-Years/m-p/638177#M476381</guid>
      <dc:creator />
      <dc:date>2014-06-03T20:38:43Z</dc:date>
    </item>
    <item>
      <title>Re: Last 3 Years</title>
      <link>https://community.qlik.com/t5/QlikView/Last-3-Years/m-p/638178#M476382</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I didn't try this one. The previous one worked for me. Thanks guys!!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 03 Jun 2014 20:39:42 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Last-3-Years/m-p/638178#M476382</guid>
      <dc:creator />
      <dc:date>2014-06-03T20:39:42Z</dc:date>
    </item>
    <item>
      <title>Re: Last 3 Years</title>
      <link>https://community.qlik.com/t5/QlikView/Last-3-Years/m-p/638179#M476383</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi npatnaik,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In straight table : Expression :&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;Only&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;({&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;fyear&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;={&lt;/SPAN&gt;&lt;STRONG&gt;&lt;EM style=": ; color: #808080; font-size: 8pt;"&gt;$(=Max({1}fyear)-2)&lt;/EM&gt;&lt;/STRONG&gt;&lt;SPAN style="font-size: 8pt;"&gt;, &lt;/SPAN&gt;&lt;STRONG&gt;&lt;EM style=": ; color: #808080; font-size: 8pt;"&gt;$(=Max({1}fyear)-1)&lt;/EM&gt;&lt;/STRONG&gt;&lt;SPAN style="font-size: 8pt;"&gt;, &lt;/SPAN&gt;&lt;STRONG&gt;&lt;EM style=": ; color: #808080; font-size: 8pt;"&gt;$(=Max({1}fyear))&lt;/EM&gt;&lt;/STRONG&gt;&lt;SPAN style="font-size: 8pt;"&gt;}&amp;gt;} &lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;fyear&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;) &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;or &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;Only&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;({&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;fyear&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;={&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;"&amp;gt;=$(=Max(fyear)-2)&amp;lt;=$(=Max(fyear))"&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;}&amp;gt;} &lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;fyear&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;) &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt; &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 03 Jun 2014 20:52:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Last-3-Years/m-p/638179#M476383</guid>
      <dc:creator>suzel404</dc:creator>
      <dc:date>2014-06-03T20:52:04Z</dc:date>
    </item>
    <item>
      <title>Re: Last 3 Years</title>
      <link>https://community.qlik.com/t5/QlikView/Last-3-Years/m-p/638180#M476384</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Michael -- Can you help me solve this problem as well?? Your last answer was bang on!!!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.qlik.com/message/543039"&gt;Calculate Contribution % for last 3 Years only&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 06 Jun 2014 00:59:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Last-3-Years/m-p/638180#M476384</guid>
      <dc:creator />
      <dc:date>2014-06-06T00:59:29Z</dc:date>
    </item>
  </channel>
</rss>

