9 Replies Latest reply on Sep 14, 2018 12:36 PM by Shinichiro Murakami

    Check if previous date is the same

    Sophie Hong-Dunnett

      Hi,

       

      I am having difficulty in trying to check if previous date (non aggregate dimension) is the same as the next date. I have tried the lookup( ) and previous_value( ) which won't work. For example:

       

      1/8

      2/8

      3/8

      3/8

      4/8

      4/8

      5/8

      6/8

       

      On a particular date, I would like to check if it is the same as the previous date? I have an if statement as below:

       

      if "date" = "previous date"

      then 0

      else 8

      end

       

      What would be the best way of doing this?

       

      Thanks

      Sophie