<?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 Pick most recent value in list in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Pick-most-recent-value-in-list/m-p/733328#M262737</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; I have a table with a field for each month Jan-Dec, each month I upload the most recent data:&lt;/P&gt;&lt;TABLE border="0" cellpadding="0" cellspacing="0" width="689"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD class="xl66" height="17" width="153"&gt;KPI&lt;BR /&gt;&amp;nbsp; Description&lt;/TD&gt;&lt;TD class="xl67" width="55"&gt;KPIMonth&lt;/TD&gt;&lt;TD class="xl65" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;" width="37"&gt;Jan&lt;/TD&gt;&lt;TD class="xl65" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;" width="37"&gt;Feb&lt;/TD&gt;&lt;TD class="xl65" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;" width="37"&gt;Mar&lt;/TD&gt;&lt;TD class="xl65" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;" width="37"&gt;Apr&lt;/TD&gt;&lt;TD class="xl65" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;" width="37"&gt;May&lt;/TD&gt;&lt;TD class="xl70" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;" width="37"&gt;Jun&lt;/TD&gt;&lt;TD class="xl70" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;" width="37"&gt;Jul&lt;/TD&gt;&lt;TD class="xl70" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;" width="37"&gt;Aug&lt;/TD&gt;&lt;TD class="xl70" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;" width="37"&gt;Sep&lt;/TD&gt;&lt;TD class="xl70" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;" width="37"&gt;Oct&lt;/TD&gt;&lt;TD class="xl70" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;" width="37"&gt;Nov&lt;/TD&gt;&lt;TD class="xl70" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;" width="37"&gt;Dec&lt;/TD&gt;&lt;TD class="xl65" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;" width="37"&gt;YTD&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl68" colspan="2" height="17" style="border-right-color: #646464; border-right-width: 0.5pt; border-right-style: solid;"&gt;Total Overhead Absorption % YTD&lt;/TD&gt;&lt;TD class="xl65" style="border-top-color: currentColor; border-left-color: currentColor; border-top-width: medium; border-left-width: medium; border-top-style: none; border-left-style: none;"&gt;103.9&lt;/TD&gt;&lt;TD class="xl65" style="border-top-color: currentColor; border-left-color: currentColor; border-top-width: medium; border-left-width: medium; border-top-style: none; border-left-style: none;"&gt;108.9&lt;/TD&gt;&lt;TD class="xl65" style="border-top-color: currentColor; border-left-color: currentColor; border-top-width: medium; border-left-width: medium; border-top-style: none; border-left-style: none;"&gt;111.5&lt;/TD&gt;&lt;TD class="xl65" style="border-top-color: currentColor; border-left-color: currentColor; border-top-width: medium; border-left-width: medium; border-top-style: none; border-left-style: none;"&gt;107.2&lt;/TD&gt;&lt;TD class="xl65" style="border-top-color: currentColor; border-left-color: currentColor; border-top-width: medium; border-left-width: medium; border-top-style: none; border-left-style: none;"&gt;102.3&lt;/TD&gt;&lt;TD class="xl70" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;"&gt;-&lt;/TD&gt;&lt;TD class="xl70" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;"&gt;-&lt;/TD&gt;&lt;TD class="xl70" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;"&gt;-&lt;/TD&gt;&lt;TD class="xl70" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;"&gt;-&lt;/TD&gt;&lt;TD class="xl70" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;"&gt;-&lt;/TD&gt;&lt;TD class="xl70" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;"&gt;-&lt;/TD&gt;&lt;TD class="xl70" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;"&gt;-&lt;/TD&gt;&lt;TD class="xl65" style="border-top-color: currentColor; border-left-color: currentColor; border-top-width: medium; border-left-width: medium; border-top-style: none; border-left-style: none;"&gt;102.3&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For YTD I need to pick the last non-zero, not-null value.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Currently I use :&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;Concatenate&lt;/P&gt;&lt;P&gt;LOAD&lt;/P&gt;&lt;P&gt;'G3' as KPIID,&lt;/P&gt;&lt;P&gt;DealerID,&lt;/P&gt;&lt;P&gt;$(KPICurrentYear) as KPIYear,&lt;/P&gt;&lt;P&gt;Dual('YTD',13) as KPIMonth,&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #0000ff; font-size: 12pt;"&gt;Pick&lt;/SPAN&gt;&lt;SPAN style="font-size: 12pt;"&gt;(&lt;SPAN style="color: #0000ff;"&gt;Month&lt;/SPAN&gt;(&lt;SPAN style="color: #0000ff;"&gt;Today&lt;/SPAN&gt;())-1, &lt;SPAN style="color: #800000;"&gt;Jan&lt;/SPAN&gt;,&lt;SPAN style="color: #800000;"&gt;Feb&lt;/SPAN&gt;,&lt;SPAN style="color: #800000;"&gt;Mar&lt;/SPAN&gt;,&lt;SPAN style="color: #800000;"&gt;Apr&lt;/SPAN&gt;,&lt;SPAN style="color: #800000;"&gt;May&lt;/SPAN&gt;,&lt;SPAN style="color: #800000;"&gt;Jun&lt;/SPAN&gt;,&lt;SPAN style="color: #800000;"&gt;Jul&lt;/SPAN&gt;,&lt;SPAN style="color: #800000;"&gt;Aug&lt;/SPAN&gt;,&lt;SPAN style="color: #800000;"&gt;Sep&lt;/SPAN&gt;,&lt;SPAN style="color: #800000;"&gt;Oct&lt;/SPAN&gt;,&lt;SPAN style="color: #800000;"&gt;Nov&lt;/SPAN&gt;,&lt;SPAN style="color: #800000;"&gt;Dec&lt;/SPAN&gt;) &lt;SPAN style="color: #0000ff;"&gt;as&lt;/SPAN&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 12pt;"&gt;OHAbsRate &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;...&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But sometimes the most recent is current month -2, so I am looking for a more robust method.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Marty.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 07 Aug 2014 11:34:23 GMT</pubDate>
    <dc:creator>martynlloyd</dc:creator>
    <dc:date>2014-08-07T11:34:23Z</dc:date>
    <item>
      <title>Pick most recent value in list</title>
      <link>https://community.qlik.com/t5/QlikView/Pick-most-recent-value-in-list/m-p/733328#M262737</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; I have a table with a field for each month Jan-Dec, each month I upload the most recent data:&lt;/P&gt;&lt;TABLE border="0" cellpadding="0" cellspacing="0" width="689"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD class="xl66" height="17" width="153"&gt;KPI&lt;BR /&gt;&amp;nbsp; Description&lt;/TD&gt;&lt;TD class="xl67" width="55"&gt;KPIMonth&lt;/TD&gt;&lt;TD class="xl65" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;" width="37"&gt;Jan&lt;/TD&gt;&lt;TD class="xl65" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;" width="37"&gt;Feb&lt;/TD&gt;&lt;TD class="xl65" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;" width="37"&gt;Mar&lt;/TD&gt;&lt;TD class="xl65" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;" width="37"&gt;Apr&lt;/TD&gt;&lt;TD class="xl65" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;" width="37"&gt;May&lt;/TD&gt;&lt;TD class="xl70" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;" width="37"&gt;Jun&lt;/TD&gt;&lt;TD class="xl70" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;" width="37"&gt;Jul&lt;/TD&gt;&lt;TD class="xl70" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;" width="37"&gt;Aug&lt;/TD&gt;&lt;TD class="xl70" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;" width="37"&gt;Sep&lt;/TD&gt;&lt;TD class="xl70" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;" width="37"&gt;Oct&lt;/TD&gt;&lt;TD class="xl70" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;" width="37"&gt;Nov&lt;/TD&gt;&lt;TD class="xl70" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;" width="37"&gt;Dec&lt;/TD&gt;&lt;TD class="xl65" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;" width="37"&gt;YTD&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl68" colspan="2" height="17" style="border-right-color: #646464; border-right-width: 0.5pt; border-right-style: solid;"&gt;Total Overhead Absorption % YTD&lt;/TD&gt;&lt;TD class="xl65" style="border-top-color: currentColor; border-left-color: currentColor; border-top-width: medium; border-left-width: medium; border-top-style: none; border-left-style: none;"&gt;103.9&lt;/TD&gt;&lt;TD class="xl65" style="border-top-color: currentColor; border-left-color: currentColor; border-top-width: medium; border-left-width: medium; border-top-style: none; border-left-style: none;"&gt;108.9&lt;/TD&gt;&lt;TD class="xl65" style="border-top-color: currentColor; border-left-color: currentColor; border-top-width: medium; border-left-width: medium; border-top-style: none; border-left-style: none;"&gt;111.5&lt;/TD&gt;&lt;TD class="xl65" style="border-top-color: currentColor; border-left-color: currentColor; border-top-width: medium; border-left-width: medium; border-top-style: none; border-left-style: none;"&gt;107.2&lt;/TD&gt;&lt;TD class="xl65" style="border-top-color: currentColor; border-left-color: currentColor; border-top-width: medium; border-left-width: medium; border-top-style: none; border-left-style: none;"&gt;102.3&lt;/TD&gt;&lt;TD class="xl70" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;"&gt;-&lt;/TD&gt;&lt;TD class="xl70" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;"&gt;-&lt;/TD&gt;&lt;TD class="xl70" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;"&gt;-&lt;/TD&gt;&lt;TD class="xl70" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;"&gt;-&lt;/TD&gt;&lt;TD class="xl70" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;"&gt;-&lt;/TD&gt;&lt;TD class="xl70" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;"&gt;-&lt;/TD&gt;&lt;TD class="xl70" style="border-left-color: currentColor; border-left-width: medium; border-left-style: none;"&gt;-&lt;/TD&gt;&lt;TD class="xl65" style="border-top-color: currentColor; border-left-color: currentColor; border-top-width: medium; border-left-width: medium; border-top-style: none; border-left-style: none;"&gt;102.3&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For YTD I need to pick the last non-zero, not-null value.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Currently I use :&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;Concatenate&lt;/P&gt;&lt;P&gt;LOAD&lt;/P&gt;&lt;P&gt;'G3' as KPIID,&lt;/P&gt;&lt;P&gt;DealerID,&lt;/P&gt;&lt;P&gt;$(KPICurrentYear) as KPIYear,&lt;/P&gt;&lt;P&gt;Dual('YTD',13) as KPIMonth,&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #0000ff; font-size: 12pt;"&gt;Pick&lt;/SPAN&gt;&lt;SPAN style="font-size: 12pt;"&gt;(&lt;SPAN style="color: #0000ff;"&gt;Month&lt;/SPAN&gt;(&lt;SPAN style="color: #0000ff;"&gt;Today&lt;/SPAN&gt;())-1, &lt;SPAN style="color: #800000;"&gt;Jan&lt;/SPAN&gt;,&lt;SPAN style="color: #800000;"&gt;Feb&lt;/SPAN&gt;,&lt;SPAN style="color: #800000;"&gt;Mar&lt;/SPAN&gt;,&lt;SPAN style="color: #800000;"&gt;Apr&lt;/SPAN&gt;,&lt;SPAN style="color: #800000;"&gt;May&lt;/SPAN&gt;,&lt;SPAN style="color: #800000;"&gt;Jun&lt;/SPAN&gt;,&lt;SPAN style="color: #800000;"&gt;Jul&lt;/SPAN&gt;,&lt;SPAN style="color: #800000;"&gt;Aug&lt;/SPAN&gt;,&lt;SPAN style="color: #800000;"&gt;Sep&lt;/SPAN&gt;,&lt;SPAN style="color: #800000;"&gt;Oct&lt;/SPAN&gt;,&lt;SPAN style="color: #800000;"&gt;Nov&lt;/SPAN&gt;,&lt;SPAN style="color: #800000;"&gt;Dec&lt;/SPAN&gt;) &lt;SPAN style="color: #0000ff;"&gt;as&lt;/SPAN&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 12pt;"&gt;OHAbsRate &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;...&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But sometimes the most recent is current month -2, so I am looking for a more robust method.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Marty.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Aug 2014 11:34:23 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Pick-most-recent-value-in-list/m-p/733328#M262737</guid>
      <dc:creator>martynlloyd</dc:creator>
      <dc:date>2014-08-07T11:34:23Z</dc:date>
    </item>
    <item>
      <title>Re: Pick most recent value in list</title>
      <link>https://community.qlik.com/t5/QlikView/Pick-most-recent-value-in-list/m-p/733329#M262738</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Unless there's any reason&amp;nbsp; you need cross tables in the in memory tables, I'd suggest converting the cross table to a straight table and then proceed from there.&lt;/P&gt;&lt;P&gt;See: &lt;A _jive_internal="true" href="https://community.qlik.com/blogs/qlikviewdesignblog/2014/03/24/crosstable" title="http://community.qlik.com/blogs/qlikviewdesignblog/2014/03/24/crosstable"&gt;http://community.qlik.com/blogs/qlikviewdesignblog/2014/03/24/crosstable&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I think the alternative is a rather lengthy construction such as:&lt;/P&gt;&lt;P&gt;alt(pick(month-1..),pick(month-2...),etc)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Aug 2014 15:01:13 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Pick-most-recent-value-in-list/m-p/733329#M262738</guid>
      <dc:creator />
      <dc:date>2014-08-07T15:01:13Z</dc:date>
    </item>
    <item>
      <title>Re: Pick most recent value in list</title>
      <link>https://community.qlik.com/t5/QlikView/Pick-most-recent-value-in-list/m-p/733330#M262739</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Japser, that is what I am doing, reading in a cross table and creating a straight table (note the 'Concatenate' in my script).&amp;nbsp; the problem comes when I need to add month 13, which is not in the source input.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Aug 2014 15:09:05 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Pick-most-recent-value-in-list/m-p/733330#M262739</guid>
      <dc:creator>martynlloyd</dc:creator>
      <dc:date>2014-08-07T15:09:05Z</dc:date>
    </item>
    <item>
      <title>Re: Re: Pick most recent value in list</title>
      <link>https://community.qlik.com/t5/QlikView/Pick-most-recent-value-in-list/m-p/733331#M262740</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;See attachment for what I had in mind.&lt;/P&gt;&lt;P&gt;Then&amp;nbsp; use the regular QV methods to load the latest month's value. (set expressions, group by, etc.)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Aug 2014 15:25:24 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Pick-most-recent-value-in-list/m-p/733331#M262740</guid>
      <dc:creator />
      <dc:date>2014-08-07T15:25:24Z</dc:date>
    </item>
  </channel>
</rss>

