cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
rbunge
Advocate IV
Advocate IV

GroupBy only if certain value in column

Use case: SharePoint list/Collection with a number of columns. One of those columns, call it ToBeGrouped, has single letter values, and I would like to GroupBy only if that value is "G". Is this at all possible? Everything I've read seems to point to "all-or-nothing", but I'm hoping someone might have some ideas.

 

Here's what the data set starts as:

Col1  Col2  Col3  ToBeGrouped  Col5

5        7        4             G                5

5        7        4             G                5

7        2        6             F                5

6        8        4             G                5

5        7        4             B                5

5        7        4             B                5

5        7        4             G                5

 

And this should be the end result:

5        7        4             G               15

7        2        6             F                5

6        8        4             G                5

5        7        4             B                5

5        7        4             B                5

 

The three lines that had G in ToBeGrouped and same values in Col1, Col2, and Col3 were grouped, and the value in Col5 was summed. The other columns were left ungrouped.

13 REPLIES 13
rbunge
Advocate IV
Advocate IV

Hi @Adrian_Celis-

 

You were absolutely right -- Coalesce works just as you indicated, and in the way I need. My apologies.

 

We're very near the finish line, but have run into one last snag. Trying to work it out, but may reach out tomorrow.

 

Thanks for the ongoing attention!

rbunge
Advocate IV
Advocate IV

No luck, @Adrian_Celis -- very much hoping you have a solution...

 

I'm adding a graphic as I think it will be easier to visualize the actual data (hopefully uploads successfully).

 

 

2021-12-01_9-20-40.jpg

 

As I mentioned in the previous post, the consolidation now works as intended, thanks to Coalesce. However, the Inventory column needs to be summed, but also needs to take into account values in the Rev column. Coalesce works fine here as well -- I've named the third column CoalescedInv, and it takes, in the example, the 200 instead of the 115.

 

However, I'm not able to get the proper sum in the consolidated row -- it shows 430.

 

I think that, since it's not a GroupBy column, it's going into the overflow table and, with the code I'm using, it will not let me reference it -- says Name isn't valid. Identified is not recognized.

rbunge
Advocate IV
Advocate IV

Following up -- any ideas?

@rbunge I have sent you a private message. Please check your inbox.

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

May UG Leader Call Carousel 768x460.png

June User Group Leader Call

Join us on June 28 for our monthly User Group leader call!

PA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

This training provides practical hands-on experience in creating Power Apps solutions in a full-day of instructor-led App creation workshop.

PA.JPG

New Release Planning Portal (Preview)

Check out our new release planning portal, an interactive way to plan and prepare for upcoming features in Power Platform.

Top Solution Authors
Users online (3,296)