The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredCompete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.
Hi Folks,
I want to calculate Same day last week sales. I am using the below dax:
Location | Department | CALENDAR_DATE_FMTD | Current Date | M.Sameday_LW Sales |
101 | 12 | 30/09/2019 0:00 | 10 | 1 |
101 | 12 | 1/10/2019 0:00 | 12 | 2 |
101 | 12 | 2/10/2019 0:00 | 13 | 3 |
101 | 12 | 3/10/2019 0:00 | 14 | 4 |
101 | 12 | 4/10/2019 0:00 | 15 | 5 |
101 | 12 | 5/10/2019 0:00 | 16 | 6 |
101 | 12 | 6/10/2019 0:00 | 17 | 7 |
101 | 12 | 7/10/2019 0:00 | 18 | 10 |
101 | 12 | 8/10/2019 0:00 | 19 | 12 |
101 | 12 | 9/10/2019 0:00 | 20 | 13 |
101 | 12 | 10/10/2019 0:00 | 21 | 14 |
101 | 12 | 11/10/2019 0:00 | 22 | 15 |
101 | 12 | 12/10/2019 0:00 | 23 | 16 |
101 | 12 | 13/10/2019 0:00 | 24 | 17 |
Total | 244 | 125 |
Location | Department | Current Date | M.Sameday_LW Sales |
101 | 12 | 24 | 125 |
Location | Department | Current Date | M.Sameday_LW Sales |
101 | 12 | 24 | 17 |
how do you "eliminate the date factor" when you still show the 24 date value? Do you have a filter elsewhere?
You may want to add variables to prevent the filter context transition from messing with your expected results.
User | Count |
---|---|
26 | |
10 | |
8 | |
6 | |
6 |
User | Count |
---|---|
31 | |
11 | |
10 | |
10 | |
9 |