<?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 How Do I Filter Pivot Table Automatically Based on Most Recent Date in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/How-Do-I-Filter-Pivot-Table-Automatically-Based-on-Most-Recent/m-p/335616#M1176916</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;So, the checkbox to limit the selection to one response is a great feature.&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;However, I don't believe that it would work in my situation.&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There will be a number of items on the page but I want to only (and always) filter the pivot table limiting it to one date. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Imagine a chart which displays data from the entire time series but when a user wants to export out the data or look at the detail, they are only allowed to look at a particular date.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks PeggySue&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 04 May 2012 12:51:33 GMT</pubDate>
    <dc:creator />
    <dc:date>2012-05-04T12:51:33Z</dc:date>
    <item>
      <title>How Do I Filter Pivot Table Automatically Based on Most Recent Date</title>
      <link>https://community.qlik.com/t5/QlikView/How-Do-I-Filter-Pivot-Table-Automatically-Based-on-Most-Recent/m-p/335614#M1176914</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;HI, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Appologies in advance!&amp;nbsp; I am new to Qlikview this week and am not a developer. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;I have a rather large table which is essentially a concatenation of data from a series of different dates.&amp;nbsp; (Think of warehouse inventory from different dates over time)&amp;nbsp; The date that the "copy" of the data was appended is in a field called the "Posted_Date".&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE border="1" cellpadding="3" cellspacing="0" class="jiveBorder" style="width: 60px; border: 1px solid #000000;"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TH align="center" style="background-color: #6690bc;" valign="middle"&gt;&lt;SPAN style="color: #ffffff;"&gt;&lt;STRONG&gt;Posted_Date&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/TH&gt;&lt;TH align="center" style="background-color: #6690bc;" valign="middle"&gt;&lt;SPAN style="color: #ffffff;"&gt;&lt;STRONG&gt;Item_Name&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/TH&gt;&lt;TH align="center" style="background-color: #6690bc;" valign="middle"&gt;&lt;SPAN style="color: #ffffff;"&gt;&lt;STRONG&gt;Data1&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/TH&gt;&lt;TH align="center" style="background-color: #6690bc;" valign="middle"&gt;&lt;SPAN style="color: #ffffff;"&gt;&lt;STRONG&gt;Data2&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/TH&gt;&lt;TH align="center" style="background-color: #6690bc;" valign="middle"&gt;&lt;SPAN style="color: #ffffff;"&gt;&lt;STRONG&gt;ETC...&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/TH&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;3/10/2012&lt;/TD&gt;&lt;TD&gt;Apples&lt;/TD&gt;&lt;TD&gt;x&lt;/TD&gt;&lt;TD&gt;x&lt;/TD&gt;&lt;TD&gt;x&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;3/10/2012&lt;/TD&gt;&lt;TD&gt;Bananas&lt;/TD&gt;&lt;TD&gt;x&lt;/TD&gt;&lt;TD&gt;x&lt;/TD&g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TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;I would like to accomplish the following items:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL style="padding-left: 30px;"&gt;&lt;LI&gt;Display the data in a pivot table (got that one &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt;)&lt;/LI&gt;&lt;LI&gt;Be able to filter the data based on a SINGLE date (I can do this if I &lt;SPAN style="text-decoration: underline;"&gt;trust &lt;/SPAN&gt;the user to select only one date from a list box ... but I &lt;SPAN style="text-decoration: underline;"&gt;don't &lt;/SPAN&gt;&lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/grin.png" /&gt;)&lt;/LI&gt;&lt;LI&gt;Therefore, what I would really like to do is... &lt;UL&gt;&lt;LI&gt;Allow the user to pick a SINGLE date from the list of possible Posted_Dates as the date for the pivot table.&lt;/LI&gt;&lt;LI&gt;Enable the system to use the most recent date if a date was not selected by the use&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;I have been trying to get my head around AGGR and ONLY functions for a couple of hours now and only managed to give myself a headache.&amp;nbsp; (Did I mention that I am not a developer type)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;I created a sample qvw in hopes that this is easy for someone who knows how to write functions.&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;I have a number of charts which show inventory levels over time.&amp;nbsp; I plan on "reusing" this code to create related charts which always show the most current data.&amp;nbsp; (Some of my charts are too complicated to use the sort and display only most recent trick).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Any and all help is greatly appreciated.&amp;nbsp; &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;PeggySue&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 May 2012 21:51:38 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-Do-I-Filter-Pivot-Table-Automatically-Based-on-Most-Recent/m-p/335614#M1176914</guid>
      <dc:creator />
      <dc:date>2012-05-03T21:51:38Z</dc:date>
    </item>
    <item>
      <title>Re: How Do I Filter Pivot Table Automatically Based on Most Recent Date</title>
      <link>https://community.qlik.com/t5/QlikView/How-Do-I-Filter-Pivot-Table-Automatically-Based-on-Most-Recent/m-p/335615#M1176915</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;He PeggySue,&lt;/P&gt;&lt;P&gt;There is an option in the listbox:always one selected value. And you could also use a trigger on open document to select the latest date.&lt;/P&gt;&lt;P&gt;See the attached file.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hopes this helps.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;gr.&lt;/P&gt;&lt;P&gt;Frank&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 May 2012 12:10:52 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-Do-I-Filter-Pivot-Table-Automatically-Based-on-Most-Recent/m-p/335615#M1176915</guid>
      <dc:creator />
      <dc:date>2012-05-04T12:10:52Z</dc:date>
    </item>
    <item>
      <title>How Do I Filter Pivot Table Automatically Based on Most Recent Date</title>
      <link>https://community.qlik.com/t5/QlikView/How-Do-I-Filter-Pivot-Table-Automatically-Based-on-Most-Recent/m-p/335616#M1176916</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;So, the checkbox to limit the selection to one response is a great feature.&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;However, I don't believe that it would work in my situation.&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There will be a number of items on the page but I want to only (and always) filter the pivot table limiting it to one date. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Imagine a chart which displays data from the entire time series but when a user wants to export out the data or look at the detail, they are only allowed to look at a particular date.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks PeggySue&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 May 2012 12:51:33 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-Do-I-Filter-Pivot-Table-Automatically-Based-on-Most-Recent/m-p/335616#M1176916</guid>
      <dc:creator />
      <dc:date>2012-05-04T12:51:33Z</dc:date>
    </item>
    <item>
      <title>Re: How Do I Filter Pivot Table Automatically Based on Most Recent Date</title>
      <link>https://community.qlik.com/t5/QlikView/How-Do-I-Filter-Pivot-Table-Automatically-Based-on-Most-Recent/m-p/335617#M1176917</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Ok, now I understand what you want. &lt;/P&gt;&lt;P&gt;You can solve this by adding an if statement in your pivot table expression:&lt;/P&gt;&lt;P&gt;if(Posted_Date=Selected_Date, Count(Department))&lt;/P&gt;&lt;P&gt;Selected_Date is a variable with the function =max(Posted_Date).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And then check the option supress when value is null&amp;nbsp; for the dimension Posted_Date.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;See the attached file.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 May 2012 13:07:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-Do-I-Filter-Pivot-Table-Automatically-Based-on-Most-Recent/m-p/335617#M1176917</guid>
      <dc:creator />
      <dc:date>2012-05-04T13:07:03Z</dc:date>
    </item>
  </channel>
</rss>

