Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi because of your help in my last discussion I set the following expression in order to get the average of sales in the last 3 three days given a particular date vDateRotura
sum({<CalendarDate={">=$(=max(date(vDateRotura-3)))<=$(=max(date(vDateRotura-1)))"}> } VENTAS.Peso)
/Count(DISTINCT {<CalendarDate={">=$(=max(date(vDateRotura-3)))<=$(=max(date(vDateRotura-1)))"}> } CalendarDate)
Now what I would like to achive is the same expression but excluding the sundays. E.g. If the given date falls on Thrusday I want the average of previous Friday+Saturday+Monday.
Any ideas?
Thanks in advance
Hi add this in the set analysis:
weekday(vDateRotura)={*}-{7}
Sorry Rakesh, I don't know exactly how to do it. Could you please lead me?
Thank you
Hi,
Due to restrictions on the system I am replying this thread I am unable to copy and paste your whole expression here, but it will will be something like this:
Sum({<CalendarDate={" ..."}, weekday(vDateRotura) = {*}-{7}>} ventas.peso)
/ Count(Disctinct {<CalendarDate={"..."}, weekday(vDateRotura)={*}-{7}>} CalendarDate)
It doesn't work. Maybe I'm doing something wrong. I didn't say that vDateRotura is a variable. Thank you anyway.