Forum Discussion
dtbsmith
Jul 11, 2023Copper Contributor
List each occurrence with a unique identifier based on type and frequency table
Hi All, Got a bit of a tough one here - I'm trying to work out a formula which is able to identify each 'instance/occurance' or a type based on the frequency value within the table (essentially ...
- Jul 11, 2023
Patrick2788
Jul 11, 2023Silver Contributor
A formula solution:
=REDUCE(
{"Itemised Result", "Unique ID", "Concat Result"},
Table1[Name],
LAMBDA(a, v,
LET(
reps, XLOOKUP(v, Table1[Name], Table1[Quantity]),
seq, SEQUENCE(reps),
names, EXPAND(v, reps, , v),
VSTACK(a, HSTACK(names, seq, names & "_" & seq))
)
)
)- dtbsmithJul 17, 2023Copper ContributorThanks Patrick - very nifty formula - however think we're going to go with the PQ option.