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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
GBlair
Regular Visitor

Need Help Creating DAX Logic using Selected Value from Slicer Based on Table with No Relationships

I'm new to Power BI and DAX.
I have a sales dataset and need to create a dashboard where users can select from a dropdown to group customers into "Bought" and "Did not Buy" buckets. The dropdown is custom and can contain individual products, product families, or groups of product families.
They can only select one item from the dropdown.

When they select an item the customer id is placed into the "bought" or "did not buy" bucket.

I modified what I think is a standard PowerBI "Financial Sample" spreadsheet.

I added Cust_ID and Product Family columns (sample below).

GBlair_0-1738885540021.png

Here's what I need to be able to do:

GBlair_1-1738885624610.png

The Sales column is total sales (all products) of customers that bought any Furniture product.
The L1 Sales are just the sales of any furniture product.
Thanks for your help, and let me know if I'm not making any sense.

1 ACCEPTED SOLUTION

@GBlair 

Glad it helped you, I have modifed the code based on your new requirement, please check it out:

Fowmy_0-1738963552867.png

 

Did I answer your question? Mark my post as a solution! and hit thumbs up


Subscribe and learn Power BI from these videos

Website LinkedIn PBI User Group

View solution in original post

5 REPLIES 5
Fowmy
Super User
Super User

@GBlair 

Please check the attached file if this is what you required.

Fowmy_0-1738915519648.png

 



Did I answer your question? Mark my post as a solution! and hit thumbs up


Subscribe and learn Power BI from these videos

Website LinkedIn PBI User Group

Thank you @Fowmy !
This got me a lot further than I was. It works for individual products. I also have the requirement that a Product Family (or group of individual products) could be selected. In that case I want to consider the customer to have bought if one or more products in the family were purchased.
But I think what you've provided allows me to play around with that requirement.
Thanks again.

@GBlair 

Glad it helped you, I have modifed the code based on your new requirement, please check it out:

Fowmy_0-1738963552867.png

 

Did I answer your question? Mark my post as a solution! and hit thumbs up


Subscribe and learn Power BI from these videos

Website LinkedIn PBI User Group

Thanks for your help. This gave me exactly what I needed.

some_bih
Super User
Super User

Hi @GBlair please clarify your part, Table with No Relationships, you mean there is only one table with all necesary data in it?
If your table is in Excel and you need simplified filtering and some measures as on picture it could be done already in Excel with Power Pivot.

If everything above is yes, share sample data excel file with expected output for some input. 





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!






Helpful resources

Announcements
July PBI25 Carousel

Power BI Monthly Update - July 2025

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

Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 community update carousel

Fabric Community Update - June 2025

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