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
Hello,
How can I make the current and prior date filtered by item selection (apple or grape).
I expect to see the slicers (current, prior) to be changed based on the item selection.
here is example pbix file:
Thank you!
Solved! Go to Solution.
Check the file at -https://www.dropbox.com/s/2w80tpj37wkiiz1/Q1.pbix?dl=0
Look at visual level filters and measure used in those and inactive relations.
Check the file at -https://www.dropbox.com/s/2w80tpj37wkiiz1/Q1.pbix?dl=0
Look at visual level filters and measure used in those and inactive relations.
Hi @topazz11 ,
The file that amitchandak created should work like a charm. I add a blog and a document where you could learn more about active relationship , inactive relationship and how to use them.
UseRelationship or Role-Playing Dimension; Dealing with Inactive Relationships in Power BI
Active vs inactive relationship guidance
Best Regards,
Xue Ding
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
@topazz11, How does the selection of dimension impact date? Try to use time intelligence along Date calendar for standard current prior
MTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESMTD('Date'[Date]))
last MTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESMTD(dateadd('Date'[Date],-1,MONTH)))
QTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESQTD(('Date'[Date])))
Last QTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESQTD(dateadd('Date'[Date],-1,QUARTER)))
YTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESYTD(('Date'[Date]),"12/31"))
This Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESYTD((ENDOFYEAR('Date'[Date])),"12/31"))
Last YTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESYTD(dateadd('Date'[Date],-1,Year),"12/31"))
Year behind Sales = CALCULATE(SUM(Sales[Sales Amount]),dateadd('Date'[Date],-1,Year))
I could not understand your question. Can you please elaborate? Why You wanted to see the slicers in that why, what should be the outcome
Proud to be a Super User!
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 39 | |
| 38 | |
| 38 | |
| 28 | |
| 27 |
| User | Count |
|---|---|
| 124 | |
| 88 | |
| 73 | |
| 66 | |
| 65 |