Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.

Reply
Anonymous
Not applicable

Dynamic Calculated Column based on field parameter selection

Hello, 

 

I created a field parameter to allow users to aggregate data by Column A or Column B.

Both of these columns store Month values (01,02,03, and so forth). 

Column A stores "Production" Months

Column B stores "Sandbox" Months


I would like to create a third dynamic column that displays Production Or Sandbox months

(depending on the users' parameter selection). 


I was hoping to use this dynamic column to join out to a dimCalendar table, so I can bring in additional information, such as # or work days within each month, etc.. 

 

I tried creating this calculated column, but I can't seem to get it to work.

Any suggestions?  Maybe I'm going about this the wrong way.

 

Toggle Sandbox/Prod Month =
VAR MySelection =
SELECTEDVALUE ( 'Parameter: Prod or Sandbox'[Parameter Name])
RETURN
SWITCH (
TRUE (),
MySelection =  "Production", Forecast[Budget Month],
MySelection =  "Sandbox", Forecast[Sandbox Month]
)
1 REPLY 1
lbendlin
Super User
Super User

 dynamic column

There is no such thing in Power BI.  Columns are static. Measures are dynamic.

Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 2025 Power BI update to learn about new features.

Top Solution Authors
Top Kudoed Authors