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

The FabCon + SQLCon recap series starts April 14th at 8am Pacific. If you’re tracking where AI is going inside Fabric, this first session is a can't miss. Register now

Reply
fcarvalho
Advocate I
Advocate I

Filter a Client and shows all Client Sales from a group

Hi, 

I need to filter a Client and then show all sales from all clients from the same group as the selected, and I'm getting stucked with that.

 

ClientsGroupsSales
Client1XPTO12312
Client2ZZZZ4324
Client4ZZZZ435
Client3XPTO2131

 

 

Example:

 

When I select Client1, shows the sales of Client1 and Client3, because they are from the same group (XPTO), or if I filter Client4, shows only Client4 and Client2 sales.

I need this filtering way, instead of filtering the group, because in my embedded solution i only can get the client parameter.

 

Client1 selected (exemple):

 

Shows a Bar Chart like that

 

Client 1 ------ 12312

Client 3 ---- 2131

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@fcarvalho , a measure like this

 

measure =
var _tab = summarize(filter('Table', 'Table'[Client] in allselected('Table'[Client])),'Table'[Groups])

return
calculate(sum(Table[Sales], filter(all(Table), Table[Groups] in _tab))

 

 

But this will work better if the client and group is an independent table

 

measure =
var _tab = summarize(filter('Client', 'Client'[Client] in allselected('Client'[Client])),'Client'[Groups])

return
calculate(sum(Table[Sales], filter(all(Table), Table[Groups] in _tab))

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

View solution in original post

1 REPLY 1
amitchandak
Super User
Super User

@fcarvalho , a measure like this

 

measure =
var _tab = summarize(filter('Table', 'Table'[Client] in allselected('Table'[Client])),'Table'[Groups])

return
calculate(sum(Table[Sales], filter(all(Table), Table[Groups] in _tab))

 

 

But this will work better if the client and group is an independent table

 

measure =
var _tab = summarize(filter('Client', 'Client'[Client] in allselected('Client'[Client])),'Client'[Groups])

return
calculate(sum(Table[Sales], filter(all(Table), Table[Groups] in _tab))

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Helpful resources

Announcements
New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

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.

Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

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