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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Dn_wemn
Helper II
Helper II

Change display name of a parameter field based on filtering another field

Hi,

I'd like to change the parameter field "Value" based on filtering another field. For example, if Category = "A" is selected,

Value should change the name to "A" in the Parameter slicer.

Dn_wemn_0-1699819846499.png

Is there a possibility to adjust the DAX statement for "Value" with this requirement?

1 ACCEPTED SOLUTION
OwenAuger
Super User
Super User

Hi @Dn_wemn 

I have attached a small example PBIX showing how you could tackle this via modelling.

You can't have dynamic expressions in the field parameter table definition, because the values within the table cannot respond to filters in the report.

 

In this case I would suggest

  1. Repeating the rows of the Parameter field parameter table for every value of Category.
  2. Adding a category column to the Parameter table.
  3. Creating a relationship between the Category column and the Parameter[Category] column.

The exact setup may need to be adjusted to fit with your existing model.

 

In my sample, the report page looks like this:

OwenAuger_2-1699832536520.png

 

Here is the definition I used for the field parameter table:

Parameter = 
VAR CategoryValues =
    ALLNOBLANKROW ( Category[Category] )
VAR ValueRows =
    SELECTCOLUMNS (
        CategoryValues,
        "Value1", Category[Category],
        "Value2", NAMEOF('_Account'[Measure 2]),
        "Value3",1,
        "Category", Category[Category]
    )
VAR AccountRows =
    SELECTCOLUMNS (
        CategoryValues,
        "Value1", "Account",
        "Value2", NAMEOF('_Account'[Account]),
        "Value3",0,
        "Category", Category[Category]
    )
RETURN
    UNION (
        ValueRows,
        AccountRows
    )

 

This produces a table like this:

OwenAuger_1-1699832477310.png

The model diagram looks like this:

OwenAuger_0-1699832397293.png

Does something like this work for you?

 

Regards


Owen Auger
Did I answer your question? Mark my post as a solution!
Blog
LinkedIn

View solution in original post

1 REPLY 1
OwenAuger
Super User
Super User

Hi @Dn_wemn 

I have attached a small example PBIX showing how you could tackle this via modelling.

You can't have dynamic expressions in the field parameter table definition, because the values within the table cannot respond to filters in the report.

 

In this case I would suggest

  1. Repeating the rows of the Parameter field parameter table for every value of Category.
  2. Adding a category column to the Parameter table.
  3. Creating a relationship between the Category column and the Parameter[Category] column.

The exact setup may need to be adjusted to fit with your existing model.

 

In my sample, the report page looks like this:

OwenAuger_2-1699832536520.png

 

Here is the definition I used for the field parameter table:

Parameter = 
VAR CategoryValues =
    ALLNOBLANKROW ( Category[Category] )
VAR ValueRows =
    SELECTCOLUMNS (
        CategoryValues,
        "Value1", Category[Category],
        "Value2", NAMEOF('_Account'[Measure 2]),
        "Value3",1,
        "Category", Category[Category]
    )
VAR AccountRows =
    SELECTCOLUMNS (
        CategoryValues,
        "Value1", "Account",
        "Value2", NAMEOF('_Account'[Account]),
        "Value3",0,
        "Category", Category[Category]
    )
RETURN
    UNION (
        ValueRows,
        AccountRows
    )

 

This produces a table like this:

OwenAuger_1-1699832477310.png

The model diagram looks like this:

OwenAuger_0-1699832397293.png

Does something like this work for you?

 

Regards


Owen Auger
Did I answer your question? Mark my post as a solution!
Blog
LinkedIn

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.