Forum Discussion
How do I filter the second parameter based on the first parameter in Power BI Report Builder?
- 4 years ago
What you are looking is cascading parameters effect.
To read and understand: https://docs.microsoft.com/en-us/power-bi/guidance/paginated-report-cascading-parameter
I saw your .rdl file, pls change these only to Dataset2
Query:
SELECT * FROM Sheet1$ WHERE [Sheet1$].Nationality = @Nationality"Dataset 2" Parameters:
and try running the report.
hope this helps!
Thanks for the detailed response. This may take me some time to fully digest. I'll run some demo reports and play around with non-cascading and cascading parameters. At some point I'm sure it would all just click. I was wondering though why do the parameters need to be linked to a seperate dataset instead of being linked to the main dataset?.
I honestly have never used SSRS. I've only very recently finished a course on SQL and began using SSMS and Report builder properly. I'm enjoying the process though. Again, I appreciate the help.
Go through these links, for detailed steps:
https://www.mssqltips.com/sqlservertip/3466/cascaded-parameters-in-sql-server-reporting-services/
https://www.tutorialgateway.org/ssrs-cascading-parameters/
I quoted SSRS because there are thousands of articles and videos exists on internet. Not to confuse you.
I added detailed information as we will doing parameters in a project through out. Better to invest time for long term.
Why do we create different datasets for each parameter?
We are using each dataset for each parameter and don't want to see the repeats.
Say, in your case, you have Nationality, Club, Players. If you have one dataset containing all three, then we see the duplicate values for nationality, club ... the idea of the dropdown will have unique list and using it will filter one more level down. A way of organizing and displaing unique items for the selection. Hope this helps!