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
I was trying to wrap my head around this requirement.
So the idea is once a user select a date ( w/c in this case a single select only )
A graph a line chart or bar chart maybe will show the 14 days before and after sales.
Been trying to search for a solution in the web w/c I saw from EDNA (5) Show Days Before Or After A Selected Date - Advanced Power BI Visual Techniques - YouTube but I think this covers only before ( I might be wrong )
Is there any leads or Info how I can achieve before and after in one single visual?
Here is the sample Pbix .
TIA
Hi @v_mark ,
You will need to create an independent date slicer table. If you use date column from original table, once the slicer being selected, the visual will only show selected date's value.
I'd like to suggest you to create a measure like below and add it to visual filter set value = 1.
measure = IF(selectedvalue('table'[date])>selectedvalue('slicer'[date])-14&&selectedvalue('table'[date])<selectedvalue('slicer'[date])+14,1,0)
Best Regards,
Jay
@amitchandak - From what I understand this Independent Date table needs to be disconnected on the main Date Table. Is there a way to use a date filter coming from the main date table. to use as a filter?
Thank you @Aburar_123 and @amitchandak. I'm sorry Seems like the pbix sample is not uploaded when I made the post.
I re-edit with the sample pbix.
Hi @v_mark,
Please follow the below steps,
1. Create a Date table
Please Mark my post as a Solution if it solves your Problem. Thanks
@v_mark , I think you need and independent date table for that
//Date1 is independent Date table, Date is joined with Table
new measure =
var _max1 = maxx(allselected(Date1),Date1[Date])
var _min = _max1 -14
var _min =_max1 + 14
return
calculate( sum(Table[Value]), filter('Date', 'Date'[Date] >=_min && 'Date'[Date] <=_max))
Need of an Independent Date Table:https://www.youtube.com/watch?v=44fGGmg9fHI
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 38 | |
| 36 | |
| 33 | |
| 30 | |
| 28 |
| User | Count |
|---|---|
| 128 | |
| 88 | |
| 79 | |
| 67 | |
| 62 |