Forum Discussion
Vicentbi
9 years agoFrequent Visitor
Getting Value Sum from previous week
Hi I have been trying to get values for previous week, unfuntuanlly it was not as easy as getting from previous month, with previousmonth function. I alreday used a grouped date on the left...
- 9 years ago
Sorry Mistake is my side.
Try this
Pre Sales =
var End_Date = MIN('Week Sales'[StartOfWeek]) -1
var Start_Date = End_Date - 6
return
CALCULATE(SUM('Week Sales'[Sales]),DATESBETWEEN('Week Sales'[Date],Start_Date,End_Date),ALLSELECTED('Week Sales'[StartOfWeek]))Small Change in your already existing formula .
Change ALLExcpet into ALLSelected, It should work
If not let me know dude.
Baskar
9 years agoResident Rockstar
Yes we can , But for that have create one calculated column like
if ( Name="A",1,2) like until how many names u have . then u have short the name with this value asc or desc.
It will only work if u have constant name , name is changing dynamically it will not helping u .