Forum Discussion
Get the Filtered values based on a bar chart
Hello Community,
I am working on a measure to get me the filtered ids based on a person and put them in a table to get the whole process of the filtered ids.
My table has three values:
- Id
- The activity presents what has been done for the id
- A person who has done the activity
My visuals are as follow:
- Table includes all the data: id, activity, Person
- Bar chart presents the count of activity by Person
I want to be able to select a person, for example, Rick and instead of getting only the activities done by Rick, I want to get ids that Rick is included in and shows all activities of these ids.
The result will look like this:
I tried to use the SelectedValue function, but it doesn't show me anything. Is there any way to implement this in Power BI?
Thank you.
Hi unkCandy
Please try this ,
Measure = var _person=SELECTEDVALUE(Person[Person]) return IF(MIN('Table'[Id]) in SELECTCOLUMNS(FILTER(ALL('Table'),'Table'[Person]=_person),"ids",[Id]) ,1,0)Best Regards,
Community Support Team _Tang
If this post helps, please consider Accept it as the solution to help the other members find it more quickly.
2 Replies
- v-xiaotangCommunity Support
Hi unkCandy
Please try this ,
Measure = var _person=SELECTEDVALUE(Person[Person]) return IF(MIN('Table'[Id]) in SELECTCOLUMNS(FILTER(ALL('Table'),'Table'[Person]=_person),"ids",[Id]) ,1,0)Best Regards,
Community Support Team _Tang
If this post helps, please consider Accept it as the solution to help the other members find it more quickly.
- v-xiaotangCommunity Support