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

Data Days is here! Join us now for 60+ days of learning, challenges, and connection. Learn more

Reply
Anonymous
Not applicable

If statement with Path

Hi Guys,

 

I have a simple problem with Path function. The situation is I have an Employees table which contains the following data:

 

ACTIVE  NAME MANAGER
True      Ali               Ara

False     Ali               Roger

 

So I need to use Path function with IF statement that only returns Path function when ACTIVE is True. For this situation I used this formule:
IF('Employees'ACTIVE = "Ture", Path('Employees'[NAME],'Employees'[MANAGER]),BLANK())

But unfortunately I got this error:
Each value in 'Employees'[NAME] must have the same value in 'Employees'[MANAGER]. The value 'Ali' has multiple values.


Thanks in advance!

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @Anonymous ,

 

I didn't get an error when using the sample data you have provided.

1.PNG

 

Best Regards,

Jay

View solution in original post

5 REPLIES 5
Anonymous
Not applicable

Hi @Anonymous ,

 

I didn't get an error when using the sample data you have provided.

1.PNG

 

Best Regards,

Jay

Anonymous
Not applicable

I really dont understand why it does now works. I used the same formule as your hahah. But thanks it works now!

Anonymous
Not applicable

Hi mohityash,

 

I understand but If I filter on Active True then it will be identical. That is why I need to use IF statement to filter Active True. But it seems like that the PATH function does not listen to the IF statement.

So is there any solution for this issue?

Thanks you!

Anonymous
Not applicable

In path function, However, if there are two identical employee IDs that have different manager IDs, the PATH function returns an error. A single manager need to be assign for Ali.
Check for reference:https://docs.microsoft.com/en-us/dax/path-function-dax

Anonymous
Not applicable

Anyone who can solve my issue?

 

Thanks in advance!

Helpful resources

Announcements
Fabric Data Days is here Carousel

Fabric Data Days 2026

Don't miss out on Data Days, June 15 through August 7. Learn Fabric, Power BI, SQL, AI and more.

May Power BI Update Carousel

Power BI Monthly Update - May 2026

Check out the May 2026 Power BI update to learn about new features.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.