Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
Is there any way to set paramaters in powerbi? I would like the users to control date ranges for the query results.
Select* from .....
WHERE [DATE] >= (@BegDate) AND [DATE] <= (@EndDate)
Solved! Go to Solution.
It is difficult to exactly what would fit your solution best but a couple of options come to mind. With both of these options you will need to pin a 'Live Page' to your dashboard rather than simply pin individual charts. Live Pages make the filter tools accessible to the user.
1. Custom Timeline Visualisation.
https://app.powerbi.com/visuals/
The Timeline visualisation at the link above allows users to select a specific timerange and can be set to Years, Quarters, Months or Days
2. Slicer Visualisation
The slicer visualisation comes as standard with Power BI. Simply create slicers for Year, Quarter or Month. Day may be a little too unfriendly to use depending on your time range. The user can then select the combination of Years, Months that suit them.
This is not as useful for linear rangers across multiple years, option 1 is better for that.
This is not really an answer to your question, but we have something similar. We have reports/dashboards we want to always come up and query data for the current month / year. We ended up adding some additional columns to our "date" table for day/month/quarter/year.
We called these date fields "relative dates" that we recalculate each night. For example, we end up with text values of "Today/Yesterday" for days, "This Month/Last Month" for months and This Year and Last Year for years - then we can create a report with a report/page filter and set it for "This Month" - that way whenever the report comes up it is always positioned to the current month.
We are using these relative date filters to provide the the date boundries on the report and then add another date filter so the user can select periods of time within the scope.
It is a bit of a hack, but seems to working fairly good so far.
It is difficult to exactly what would fit your solution best but a couple of options come to mind. With both of these options you will need to pin a 'Live Page' to your dashboard rather than simply pin individual charts. Live Pages make the filter tools accessible to the user.
1. Custom Timeline Visualisation.
https://app.powerbi.com/visuals/
The Timeline visualisation at the link above allows users to select a specific timerange and can be set to Years, Quarters, Months or Days
2. Slicer Visualisation
The slicer visualisation comes as standard with Power BI. Simply create slicers for Year, Quarter or Month. Day may be a little too unfriendly to use depending on your time range. The user can then select the combination of Years, Months that suit them.
This is not as useful for linear rangers across multiple years, option 1 is better for that.
There has got to be a better way to filter on date ranges. Yes, the "Timeline" visualization functions, but it is not a friendly tool. It is a pain to use. Why not simply allow a popup calendar to select a start and end date?
Looks like the time slicer may work. How do I pass the timeslicer dates into my data set query?
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.