Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
Solved! Go to Solution.
Hi @shakobe1 ,
You can try the following code I modified:
SKU sales total (Date 1) =
VAR startdate = CALCULATE(min('Date'[Calendar Date]),ALL('Independent Date'))
VAR enddate = CALCULATE(MAX('Date'[Calendar Date]),ALL('Independent Date'))
return
CALCULATE(Average('Measure Table'[Sales Line Quantity]), ALL('Independent Date'[Calendar Date]), DATESBETWEEN('Independent Date'[Calendar Date],startdate,enddate))
If the above code does not meet your requirements, can you provide some test data and sample expected results?
Best Regards,
Yolo Zhu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi Yolo! unfortunately it dodnt work. I attached a screen shot
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
Check out the November 2025 Power BI update to learn about new features.
| User | Count |
|---|---|
| 20 | |
| 10 | |
| 9 | |
| 4 | |
| 4 |
| User | Count |
|---|---|
| 32 | |
| 31 | |
| 18 | |
| 12 | |
| 11 |