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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
SEBot
Frequent Visitor

What if Parameter for single row

Hello,

 

Is it possible to create a parameter with a generateseries (0,100,1) that only changes the value of a single row of a table? For example, I would want to be able to have a paramenter only for "Y" in column 1. So when I change the paramenter only the amount in column 2 would change for "Y"? Ultimatly I would want individual paramenters for X,Y, and Z.

 

Right now if I create a parament the amount in column 2 changes for X, Y, and Z.

 

Column 1Column 2 (Amount)
X0
Y0
Z0
1 ACCEPTED SOLUTION
v-shex-msft
Community Support
Community Support

Hi @SEBot,

Currently, power bi does not support to create a dynamic calculated column/table based on filter/slicer.
You need to create a measure formula with switch function to check each row label and return correspond selector table value:

Measure = 
SWITCH (
    SELECTEDVALUE ( 'Table'[Label] ),
    "a", SELECTEDVALUE ( PA[PA], SUM ( PA[PA] ) ),
    "b", SELECTEDVALUE ( PB[PB], SUM ( PB[PB] ) ),
    "c", SELECTEDVALUE ( PC[PC], SUM ( PC[PC] ) ),
    "d", SELECTEDVALUE ( PD[PD], SUM ( PD[PD] ) ),
    BLANK ()
)

12.png

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin
If this post helps, please consider accept as solution to help other members find it more quickly.

View solution in original post

1 REPLY 1
v-shex-msft
Community Support
Community Support

Hi @SEBot,

Currently, power bi does not support to create a dynamic calculated column/table based on filter/slicer.
You need to create a measure formula with switch function to check each row label and return correspond selector table value:

Measure = 
SWITCH (
    SELECTEDVALUE ( 'Table'[Label] ),
    "a", SELECTEDVALUE ( PA[PA], SUM ( PA[PA] ) ),
    "b", SELECTEDVALUE ( PB[PB], SUM ( PB[PB] ) ),
    "c", SELECTEDVALUE ( PC[PC], SUM ( PC[PC] ) ),
    "d", SELECTEDVALUE ( PD[PD], SUM ( PD[PD] ) ),
    BLANK ()
)

12.png

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin
If this post helps, please consider accept as solution to help other members find it more quickly.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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