Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
Hi, I am completely tearing my hair out here. I have no idea why this doesn't work.
Basically, I am trying to select a column based on a selected value (which is in turn, chosen via slicer) using a switch statement. Here is my DAX code that DOES NOT WORK (Table & column names edited for anonymity):
Hello
Did u get the solution for the above?
I am also facing the same problem..if you have a solution ..kindly share
Are you trying to dynamically select a column to display in a visual? If so, field parameters are a great option:
https://learn.microsoft.com/en-us/power-bi/create-reports/power-bi-field-parameters
Or, are you trying to dynamically select a column's value for further use in your measure? It's worth noting that a calculated column can't recognize a slicer selection, so a measure is the only option.
Proud to be a Super User!
I am trying to dynamically select a column to display in a visual. I clicked your link but for me there is no "Preview Features" in the options menu, so I can't do it.
Is there a way to do this with a measure instead of a calculated column? I want all the rows to display in a visual, not an aggregation.
What version of Power BI Desktop do you have? If you don't see "Field parameters" below, upgrade Power BI Desktop:
Proud to be a Super User!
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
10 | |
8 | |
8 | |
8 | |
6 |
User | Count |
---|---|
14 | |
12 | |
11 | |
9 | |
9 |