5 Replies Latest reply: Aug 22, 2018 11:53 AM by Bala Bhaskar RSS

    Rolling Date

    Ism Qui

      I am trying to create a measure that will use data only from last 30 days, but have not been able to get the correct syntax for my expression:


      SUM(aggr(IF(floor([completed_date.autoCalendar.Date])>=num(today())-30 and floor([completed_date.autoCalendar.Date])<= num(today()),[completed_date.autoCalendar.Date],null()), SUM(aggr(sum({$<order_type={'sales'}>}distinct quantity), order_product_id))))


      Any help to modify this expression?  Thanks in advance.