5 Replies Latest reply on Oct 30, 2018 5:10 AM by Zhouyi Zhang

    Combine YTD calculation with count distinct

    Barry van der Pol

      Is it possible to combine a last year or year to date formula with a count distinct. For example to see the number of orders with more than x euro sales

      I tried to combine these two but it not seems to work and i can't find the solution.

       

      IF ([WEEK_BEGIN_DATUM] <= TODAY()

      AND DATEDIFF('year',[WEEK_BEGIN_DATUM],Today())= 0) THEN COUNTD(IF [sales] >0 THEN [article number]END)