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

We've captured the moments from FabCon & SQLCon that everyone is talking about, and we are bringing them to the community, live and on-demand. Starts on April 14th. Register now

Reply
Anonymous
Not applicable

How to aggregate

 

Hi PBI Experts,

 

I'm new to PowerBI so appreciate anyone's assistance here. How do I aggregate some selected rows below. E.g. I want to group together Australia, Canada and LATAM into a "Other" summing up its sales revenue since they are not relevant but I don't want to mess up the total at the bottom of the table? I want to preserve the other rows. I'm not sure how this will work with the % values like 'Growth %' and Index %. 

 

But would appreciate guidance on grouping some of the countries below. Thanks!

Capture.JPG

1 ACCEPTED SOLUTION
Johanno
Continued Contributor
Continued Contributor

Ok, try this Smiley Happy

1. In the Menu bar press Modeling

2. Click New Column

3. Paste the code I wrote before, but change the name for the table and if you want to change the name of the column "Region2"

4. Press Enter

5. Select your table and drag and drop the new Region2 to the table

View solution in original post

3 REPLIES 3
Johanno
Continued Contributor
Continued Contributor

Hi, you could do the grouping by creating a calculated column like:

Region2 = SWITCH(Table1[Region];"Australia";"Other";"Canada";"Other";"Latam";"Other";Table1[Region])

Then you add this column to the table instead of the old one. I guess your percentage would still be right, if not add another screen shot.

Anonymous
Not applicable

Folks, I'm super new to PowerBI. Now even sure how to implement these instructions. I appreciate it though but could someone provide some steps to make this work. Thanks!

Johanno
Continued Contributor
Continued Contributor

Ok, try this Smiley Happy

1. In the Menu bar press Modeling

2. Click New Column

3. Paste the code I wrote before, but change the name for the table and if you want to change the name of the column "Region2"

4. Press Enter

5. Select your table and drag and drop the new Region2 to the table

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.