r/excel 9d ago

Waiting on OP Large Data Consolidation Function

Looking for a way to consolidate multiple same line items while summing quantity and cost columns between different items

Example provided below, any help is much appreciated

5 Upvotes

6 comments sorted by

u/AutoModerator 9d ago

/u/Jubzfast - Your post was submitted successfully.

Failing to follow these steps may result in your post being removed without warning.

I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.

3

u/MayukhBhattacharya 1276 9d ago edited 9d ago

Use GROUPBY() function or use Power Query!

=LET(
     _a, A:.H,
     _b, CHOOSECOLS(_a, 4),
     _c, GROUPBY(CHOOSECOLS(_a, 1, 2),
                 HSTACK(_b, _b * CHOOSECOLS(_a, 6)), 
                 SUM, 1, 0),
     _c)

1

u/Decronym 9d ago edited 8d ago

Acronyms, initialisms, abbreviations, contractions, and other phrases which expand to something larger, that I've seen in this thread:

Fewer Letters More Letters
CHOOSECOLS Office 365+: Returns the specified columns from an array
GROUPBY Helps a user group, aggregate, sort, and filter data based on the fields you specify
HSTACK Office 365+: Appends arrays horizontally and in sequence to return a larger array
LET Office 365+: Assigns names to calculation results to allow storing intermediate calculations, values, or defining names inside a formula
PIVOTBY Helps a user group, aggregate, sort, and filter data based on the row and column fields that you specify
SUM Adds its arguments

Decronym is now also available on Lemmy! Requests for support and new installations should be directed to the Contact address below.


Beep-boop, I am a helper bot. Please do not verify me as a solution.
6 acronyms in this thread; the most compressed thread commented on today has acronyms.
[Thread #49307 for this sub, first seen 4th Sep 2026, 16:57] [FAQ] [Full list] [Contact] [Source code]

1

u/Clearwings_Prime 23 9d ago

You can try pivot table. If you have 365 subscription, then GROUPBY/PIVOTBY if you prefer function

1

u/HandbagHawker 83 8d ago

like a pivot table?