Forum Discussion
LousQuinn
Dec 09, 2022Copper Contributor
Group tranposed data
Hello, I'm having difficulty 'grouping' the transposed data - so as attached, if the account in colum A matches/is the same, rather than creating separate transposed colums, all amounts will appe...
Lorenzo
Dec 09, 2022Silver Contributor
Hi LousQuinn
A 365 alternative assuming you have functions HSTACK & VSTACK:
In I3:
=LET(
Header, TRANSPOSE(UNIQUE(TBL_Source[Account])),
StackAmt, REDUCE(0,Header,
LAMBDA(seed,acct, HSTACK(seed, FILTER(TBL_Source[Amount],TBL_Source[Account]=acct)))
),
Clean, IFNA(DROP(StackAmt,,1),""),
VSTACK(Header, Clean)
)LousQuinn
Dec 12, 2022Copper Contributor
Thanks for both you answers
- LorenzoDec 12, 2022Silver ContributorYou're welcome. If any of them does what you expect please mark it as solution to help those who search this site - Thanks & nice day...
- LousQuinnDec 12, 2022Copper ContributorOk will test both solutions asap. thanks again
- LorenzoDec 27, 2022Silver Contributor
Another 365 option
in I9:
=LET( JoinAmts, LAMBDA(Amounts,Accounts,account, TEXTJOIN(";",,FILTER(Amounts,Accounts=account)) ), Accts, TRANSPOSE(UNIQUE(TBL_Source[Account])), StackedValues, REDUCE("",Accts, LAMBDA(seed,acct, VSTACK(seed,JoinAmts(TBL_Source[Amount],TBL_Source[Account],acct))) ), VSTACK( Accts, TRANSPOSE(IFNA(NUMBERVALUE(TEXTSPLIT(TEXTJOIN("|",TRUE,StackedValues),";","|")),"")) ) )