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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more

Reply
Anonymous
Not applicable

Filter if customer bought certain products

Hello

 

I would like to be to be able to choose multiple products and then see if a customer had bought all selected products. 

 

Example: My table looks like this. 

 

I have a slicer with the Product name. When I choose lets say Bike and Car in the Slicer, I would like the Result to be Yes/No if that customer bought those two products or not.

 

Thanking you in advance

 

Client IDProduct Name
1Bike
2Bike
3Car
1Car
2Car
1Boat
1 ACCEPTED SOLUTION
Samarth_18
Community Champion
Community Champion

Hi @Anonymous ,

 

Try to create a measure with below code:-

Bought(Y/N) =
IF (
    MAX ( 'Product'[Product Name] ) IN VALUES ( 'Product'[Product Name] ),
    "YES",
    "NO"
)

 

Output:-

Samarth_18_0-1643042483502.png

 

Thanks,

Samarth

 

Best Regards,
Samarth

If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
Connect on Linkedin

View solution in original post

3 REPLIES 3
Syndicate_Admin
Administrator
Administrator

Good morning Samarth

Thank you so much! It works great

Joe

Samarth_18
Community Champion
Community Champion

Hi @Anonymous ,

 

Try to create a measure with below code:-

Bought(Y/N) =
IF (
    MAX ( 'Product'[Product Name] ) IN VALUES ( 'Product'[Product Name] ),
    "YES",
    "NO"
)

 

Output:-

Samarth_18_0-1643042483502.png

 

Thanks,

Samarth

 

Best Regards,
Samarth

If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
Connect on Linkedin

Anonymous
Not applicable

@Anonymous HI, where exactly you want to see yes/no is it for each row of customer name table or individually?

 

if you have any flag/identifyer to know if a customer purchased any product and then we can use this flag to create additional column for your purpose.

 

Regards,
John Basha Mattipati,
https://www.linkedin.com/in/john-basha-mattipati-06812980/

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors