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

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Reply
Aikeno
Frequent Visitor

Multicolumns filter

Hello everyone,

I have published a report with a matrice of this type (see below):

 

Project

Contact

Backup

Start

End

500

Benoit

Jean

 

 

600

Jean

Fabien

 

 

700

David

Fabien

 

 

800

Jean

Eude

 

 

 

The goal is to use a segment, filter or somethings that will allow me to filter all of the projects in which Jean is mentionned as contact or backup. 
Im not able to get this result. Do you know how i can achieve that ?
Thanks in advance for your help !

3 REPLIES 3
Timuran
Resolver I
Resolver I

@Aikeno 

The first thing is creating a new table with distinct values of Contact and Backup.
You can do as follow :

 

DistinctContactBackup = DISTINCT(UNION(DISTINCT(YOUR_TABLE[Contact]), DISTINCT(YOUR_TABLE[Backup])))

 

 

Then create a measure with the following :

 

 

Selected Contact Or Backup = SELECTEDVALUE('DistinctContactBackup'[Contact])

 

 

After, create a measure with the following (like what @Greg_Deckler told you):

 

 

 

Selector Contact Backup = IF( MAX(YOUR_TABLE[Contact]) = [Selected Contact Or Backup] || MAX(YOUR_TABLE[Backup]) = [Selected Contact Or Backup], 1, 0)

 

 

 

On your visual, add the measure and filter when the measure "Selector Contact Backup" = 1.

 

Add a segment with the values of your new table DistinctContactBackup.

 

Then you need to select the value you want.

 

Have a nice day.

Greg_Deckler
Super User
Super User

@Aikeno You need to use a Complex Selector: The Complex Selector - Microsoft Fabric Community. In your case something like:

Complex Selector Measure = 
  VAR __Target = "Jean"
  VAR __Contact = MAX( 'Table'[Contact] )
  VAR __Backup = MAX( 'Table'[Backup] )
  VAR __Result = IF ( __Contact = __Target || __Backup = __Target, 1, 0 )
RETURN
  __Result

Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...

Hello,

 

Sorry for my late answer.

My need is to use a slicer to select the name as shown in your example.

I try to use your example but I think i don't get the good formatting for it.

 

Thanks for your help.

Helpful resources

Announcements
Europe Fabric Conference

Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.

July 2024 Power BI Update

Power BI Monthly Update - July 2024

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

July Newsletter

Fabric Community Update - July 2024

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