Forum Discussion

JeanGoodrich's avatar
JeanGoodrich
Copper Contributor
Aug 02, 2022
Solved

Merged subcells and displaced data

I have a data file produced as output by a third-party program (i.e., I'm stuck with it, as is). Data input into Column E is usually one line/one cell in size. However, I have some data appearing in ...
  • Patrick2788's avatar
    Patrick2788
    Aug 03, 2022

    JeanGoodrich 

     

    Attached is a possible LAMBDA solution. Please note my solution accounts for 6 columns. I see there were a few entries in the column right of Skill so I included it in the calculations.

     

    Fill-in gaps in the data:

     

    =LAMBDA(arr,col_num,SCAN("",INDEX(arr,SEQUENCE(ROWS(arr)),col_num),LAMBDA(a,v,IF(v="",a,v))))

     

    Piece it all together:

     

    =LAMBDA(arr,CHOOSE({1,2,3,4,5,6},FILL(arr,1),FILL(arr,2),FILL(arr,3),FILL(arr,4),INDEX(TEXT(arr,";;;General"),SEQUENCE(ROWS(arr)),5),INDEX(TEXT(arr,";;;General"),SEQUENCE(ROWS(arr)),6)))

     

    I avoided using insider functions which would have made it simpler.

     

    The end result (all you need to give CLEANUP is the entire range, including header row):

     

     

Resources