GROUPBY Function And Merged Cells

Copper Contributor

How to Deal With Merged Cells in Excel if you want to summarize your data with GROUPBY 

 

2024-02-28_102032.png

here is my first try :

 

2024-02-28_102255.png



=GROUPBY(
  WRAPCOLS(
    SCAN(
      ,
      TOCOL(B7:C24, , 1),
      LAMBDA(x, y, IF(y = "", x, y))
    ),
    ROWS(B7:C24)
  ),
  D7:F24,
  SUM
)

a Powerful use of my custom Excel function FILLDATA is demonstrated in situations like this, where the first two columns (which would be used as the Row Field in the GROUPBY function) have merged cells.
And that is the solution with FILLDATA Function :

 

2024-02-28_102338.png

 


=GROUPBY(FILLDATA(B7:C24, "d", , ), D7:F24, SUM)
 
 FILLDATA is a custom function built using LAMBDA  that automates the process of filling empty cells in your spreadsheets in all Directions (Down – Up – Right – Left )

If you want to know more about it , check out this Post :
https://lnkd.in/d82GChJW


if you find it useful , please vote for it:
https://lnkd.in/dvYe3JnQ



 

 

0 Replies