Hello. I have a DAX formula to calculate sales from the previous day:
Sales yesterday = CALCULATE(sum([Sales]),PREVIOUSDAY([Date]))
The function works well, however when there is no sales for a particular day, I won't see the sales amount from the previous day (see in yellow)
How can I fix this?
Sales yesterday = CALCULATE(sum([Sales]),PREVIOUSDAY([Date]))+0
Proud to be a Super User!
Thank you for the quick response, but it only added zeros...
Take Previous Day on time table
PriorDay Sales = CALCULATE(SUM(Sales[Sales_amount]),PREVIOUSDAY(Curr_Date[Sales_date]))
In my case Curr_date is marked as time table in power BI
Some even dates are missing
Check out the on demand sessions that are available now!
Check out the Winners!
Features releasing from October 2020 through March 2021