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

A new Data Days event is coming soon! This time we’re going bigger than ever. Fabric, Power BI, SQL, AI and more. Don't miss out.

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
May Power BI Update Carousel

Power BI Monthly Update - May 2026

Check out the May 2026 Power BI update to learn about new features.

Fabric SQL PBI Data Days

Data Days 2026 coming soon!

Sign up to receive a private message when registration opens and key events begin.

New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.