2 Replies Latest reply: Aug 13, 2017 1:55 PM by Antonio Mancini RSS

    Compare two dates

    Tal Tal

      Hi,

      I want to add another column that will compare the Sale$ amount for the maximum (selected) month with Previous Month

      But the comparison will take into account the days of the selected month.
      For example, if the user selects current month, 13.8

      therefore the comparison will be from 1.8 till 13.8 and from 1.7 till 13.7 (13 days)


      also,

      If the percentage is positive, meaning there is an increase in sales, the number will be colored in black and an arrow will appear next to it.

      If there is a decrease in the sale, the data will be colored in red and a downward arrow appears.

       

       

      as well,

      Can I add an option, that the user will select the months for which he wants to perform the comparison.

      For example, 6.2017 vs. 7.2017

        • Re: Compare two dates
          Oleg Troyansky

          Hi Tal,

           

          actually, your two questions require two completely different solution.

           

          1. In order to compare this month to the previous month, you can implement a set of calendar flags and incorporate the condition about the current month-to-date versus previous month-to-date in the calculation of the flags.

           

          2. In order to enable user selection of the month to compare to, you need to implement Alternate States and compare sets of data in two different alternate states. In this case, you'd probably need to include the condition about the current month in your calculation.

           

          IF( <current month condition>, <MTD calculation>, <full month calculation>)

           

          Cheers,

          Oleg Troyansky

          Upgrade your Qlik skills at the Masters Summit for Qlik - coming to Boston, MA this October!

          • Re: Compare two dates
            Antonio Mancini

            Hi Tal Tal,

            see Attachment.

            Regards,

            Antonio,