2 Replies Latest reply: Mar 7, 2018 2:14 AM by max payne RSS

    Sum values of max date of period

    Daniel Valenti

      Hello,

       

      I need to develop a measure in Qlik Sense that sums the product quantities of the last day of the period. Here goes some explanation of the measure and visualization:

      • The period of visualization can change, it can be: Year, Month, Quarter, Week, Day ...
      • The database has the information of quantity of products per day

      Here goes some examples:

       

      Database:

      Date (MM/DD/YY)ProductQuantity
      01/01/18A10
      01/01/18B20
      01/01/18C30
      01/15/18A5
      01/15/18B50
      01/15/18C100
      01/15/18D80
      02/01/18A5
      02/01/18B15
      02/01/18C20
      02/08/18A15
      02/08/18B30
      02/08/18C30
      02/08/18D50

       

      So lets see some visualizations that I would like:

       

      Visualization 1:

      Date (MM/DD/YY)Quantity
      01/01/1860
      01/15/18235
      02/01/1855
      02/08/18

      110

       

      Visualization 2:

      MonthQuantity
      Jan235
      Feb110

       

      Visualization 3: (This one uses the max date, in this case 02/08/2018)

      ProductQuantity
      A0
      B30
      C30
      D50

       

      Visualization 4:

      MonthProductQuantity
      JanA5
      JanB50
      JanC100
      JanD80
      FebA0
      FebB30
      FebC30
      FebD50

       

      I think it is not a good idea to use AGGR, because the database is very big and there are more information about the products that can be put in the visualization. Can anyone help me?

       

      Thanks in advance.

       

      Daniel