Forum Discussion
SelectedValues will not filter on multiple values
Hello,
What data types are 'Main Account'[Account Type] and 'Accounts'[Account Type] ?
Regards,
ElenaN
Text
- v-cherch-msft7 years agoMicrosoft Employee
Hi rwyoung01
You may try below measure and drag it into table visual or use it as visual level filter.If it is not your case,please show us some screenshot of the table and error.
AccountTypeWPrisoner = IF ( SELECTEDVALUE ( 'Main Account'[AccountType] ) = "Main Account Types(with Prisoners)" && MAX ( Accounts[AccountType] ) IN { "Business", "Chaplain", "Church", "Directgiv", "Ministry", "Minor", "Prisoner", "Regular", "Orgcontact" }, 1 )Regards,
Cherie
- rwyoung017 years agoFrequent Visitor
ok, that eliminated the error but no charts on that page get filtered. Here is what I am trying to do. I have an Account table with the AccountType as one of the columns. I have added a ClicletSlicer that has two options. When I select "Main Account Types(with Prisoners), I want it to filter the Account Table. It would be the same as adding the AccountType as a Page Level or Report Level filter and making the user select which types of AccountType he wants to filter on. But I want it to be done using the ClicletSlicer to do the filtering of all charts on that page that use the Accounts table. I added the above code as a Measure on the Accounts table.
- v-cherch-msft7 years agoMicrosoft Employee
Hi rwyoung01
You may try to add the measure to visual level filters for all the charts which need to be filtered like below:
https://www.sqlbi.com/articles/applying-a-measure-filter-in-power-bi/
Regards,
Cherie