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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
bilingual
Helper V
Helper V

Agregate names based on percentage

Hi everbody i am struggling with some differences Excel vs PowerBI  

 

I have this data (Example)

 

Name (Text)NumberPercentage of total (calculated measure) 
A10010 
B505 

C

20020 
D505 
E10010 
F10010 
G505 
H20020 
I10010 
J505 

 

I need to find a measure which can aggregate both percentage and names, for example if i want to aggregate values less/equual to 5 percent:

Name (Text)NumberPercentage of total (calculated measure) 
A10010 

C

20020 
E10010 
F10010 
H20020 
I10010 
Combined Names with less than/equal to 5 percent 20020 

 

How is the easiest way to do so? - mind the percentage of total is a measure

In Excel it would be an IF formular

Kind regards Daniel

 

4 REPLIES 4
v-yalanwu-msft
Community Support
Community Support

Hi, @bilingual ;

Is your problem solved?  If so, kindly mark the proper reply as a solution to help others having the similar issue and close the case. If not, let me know and I'll try to help you further.


Best Regards,
Community Support Team _ Yalan Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

v-yalanwu-msft
Community Support
Community Support

Hi, @bilingual ;

You nees another table then create a measure.

1.create a table.

Name = UNION( FILTER( VALUES('Table'[Name (Text)]),[Percentage of total]>5),{"less than/equal to 5 percent "})

2.create a measure.

Measure = IF(MAX('Name'[Name (Text)]) in VALUES('Table'[Name (Text)]), 
CALCULATE([Percentage of total],FILTER('Table',[Name (Text)]=MAX('Name'[Name (Text)]))),
SUMX(SUMMARIZE(FILTER('Table',[Percentage of total]<=5),"1",[Percentage of total]),[1]))

The final show:

vyalanwumsft_0-1665127972091.png


Best Regards,
Community Support Team _ Yalan Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Thanks a lot, however as my primarry Data contains Dates as well and there Duplicate Names , it seems to have problems using for example week samples, could you maybe help? 🙂

Hi, @bilingual ;

So what does your sample look like? Can you update your sample and the results you wish to output?


Best Regards,
Community Support Team _ Yalan Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

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