3 Replies Latest reply: May 4, 2012 9:07 AM by frank crezee RSS

    How Do I Filter Pivot Table Automatically Based on Most Recent Date

      HI,

       

      Appologies in advance!  I am new to Qlikview this week and am not a developer.

       

      I have a rather large table which is essentially a concatenation of data from a series of different dates.  (Think of warehouse inventory from different dates over time)  The date that the "copy" of the data was appended is in a field called the "Posted_Date".

       

      Posted_DateItem_NameData1Data2ETC...
      3/10/2012Applesxxx
      3/10/2012Bananasxxx
      3/10/2012Carrotsxxx
      2/18/2012Applesxxx
      2/18/2012Bananasxxx
      2/18/2012Carrotsxxx
      1/07/2012Applesxxx
      1/07/2012Bananasxxx
      1/07/2012Carrotsxxx

       

      I would like to accomplish the following items:

       

      • Display the data in a pivot table (got that one )
      • Be able to filter the data based on a SINGLE date (I can do this if I trust the user to select only one date from a list box ... but I don't )
      • Therefore, what I would really like to do is...
        • Allow the user to pick a SINGLE date from the list of possible Posted_Dates as the date for the pivot table.
        • Enable the system to use the most recent date if a date was not selected by the use

       

       

      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.  (Did I mention that I am not a developer type)

       

      I created a sample qvw in hopes that this is easy for someone who knows how to write functions. 

       

      I have a number of charts which show inventory levels over time.  I plan on "reusing" this code to create related charts which always show the most current data.  (Some of my charts are too complicated to use the sort and display only most recent trick).

       

      Any and all help is greatly appreciated. 

       

      Thanks

      PeggySue