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

Be one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now

Reply
MiteshY
Frequent Visitor

ADDING COLUMN VALUES TO SELECTED PARAMETER

Hello All,  

 

I have one question and i am not sure is it possible in power bi or not.

 

There is a column of user name in table and i want to specify some criteria to it based on user selection.

 

Eg. Column name is user name and i have created one table name Selection.

 

I want to add user name to selection which i have made.

 

Suppose username is Cat and in selection there are 2 dropdowns Animal and Not animal.

So if someone selects Animal then value sholud be added to animal field in selection.

 

In this way i want dynamic value based on selection , 

 

PLEASE HELP, IF WE CAN APPLY THIS IN POWER BI OR THERE ARE SOME OTHER WAYS TO ACHIEVE.

 

Thanks.

2 REPLIES 2
BeaBF
Memorable Member
Memorable Member

@MiteshY Hi!

Yes, it is possible to achieve the functionality you described in Power BI. You can use a combination of slicers and calculated columns to add the username to a specific category based on user selection.

Here are the steps you can follow:

  1. Create a slicer for the "User Name" column in your table.

  2. Create two additional slicers for the "Animal" and "Not Animal" categories.

  3. Add a new calculated column to your table using the DAX formula:Category =
    IF(
    SELECTEDVALUE('Selection'[Animal]) = "Animal",
    "Animal",
    IF(
    SELECTEDVALUE('Selection'[Not Animal]) = "Not Animal",
    "Not Animal",
    BLANK()
    )
    )

  4. Add the new "Category" column to your table visual.

  5. When a user selects a username in the "User Name" slicer, they can also select either "Animal" or "Not Animal" from the corresponding slicer to assign the user to the selected category.BBF

Thank you @BeaBF for your response.

 I have tried what you have said above, but i am not getting the desired output. It would be great if you can share sample file.

 

 

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

Dec Fabric Community Survey

We want your feedback!

Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.

ArunFabCon

Microsoft Fabric Community Conference 2025

Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.

Top Kudoed Authors