Reading a quantity in a cell and separating into rows... kind of hard to explain

sparanthony

New Member
Joined
Oct 18, 2022
Messages
4
Office Version
  1. 365
Platform
  1. Windows
Is there a formula where it can somehow automatically read the quantity in a cell that I need of each team name, and list them in a new column.
For example
Column 1 has the quantity: 7
Column 2 has the team name: Sharks
Column 3 has sport: hockey
Column 4 has school: Sample HS

I need the quantity listed for the whole row to separate 7 times. See photo for example.

Any help is greatly appreciated!

Thanks!
 

Attachments

  • excel_problem.jpg
    excel_problem.jpg
    156.7 KB · Views: 7

Excel Facts

How to fill five years of quarters?
Type 1Q-2023 in a cell. Grab the fill handle and drag down or right. After 4Q-2023, Excel will jump to 1Q-2024. Dash can be any character.
Hi & welcome to MrExcel.
How about
Fluff.xlsm
ABCDEFGH
1QtyPostCodeIn Use?Latitude
23BN1 7GBYes50.84139BN1 7GBYes50.84139
32CB25 0DUYes52.27783BN1 7GBYes50.84139
41LS13 3DJYes53.80972BN1 7GBYes50.84139
50SO51 7SAYes50.99463CB25 0DUYes52.27783
62ST16 3QUYes52.81398CB25 0DUYes52.27783
70E5 0QGYes51.55804LS13 3DJYes53.80972
80SG13 7FZYes51.80031ST16 3QUYes52.81398
93SN2 1BDYes51.56901ST16 3QUYes52.81398
104TW3 1NNYes51.47086SN2 1BDYes51.56901
112SL6 4EDYes51.51571SN2 1BDYes51.56901
12SN2 1BDYes51.56901
13TW3 1NNYes51.47086
14TW3 1NNYes51.47086
15TW3 1NNYes51.47086
16TW3 1NNYes51.47086
17SL6 4EDYes51.51571
18SL6 4EDYes51.51571
19
Data
Cell Formulas
RangeFormula
F2:H18F2=LET(rs,SCAN(0,A2:A11,LAMBDA(a,b,a+b)),INDEX(B2:D11,XMATCH(SEQUENCE(SUM(A2:A11)),rs,1),{1,2,3}))
Dynamic array formulas.
 
Upvote 0
Hi & welcome to MrExcel.
How about
Fluff.xlsm
ABCDEFGH
1QtyPostCodeIn Use?Latitude
23BN1 7GBYes50.84139BN1 7GBYes50.84139
32CB25 0DUYes52.27783BN1 7GBYes50.84139
41LS13 3DJYes53.80972BN1 7GBYes50.84139
50SO51 7SAYes50.99463CB25 0DUYes52.27783
62ST16 3QUYes52.81398CB25 0DUYes52.27783
70E5 0QGYes51.55804LS13 3DJYes53.80972
80SG13 7FZYes51.80031ST16 3QUYes52.81398
93SN2 1BDYes51.56901ST16 3QUYes52.81398
104TW3 1NNYes51.47086SN2 1BDYes51.56901
112SL6 4EDYes51.51571SN2 1BDYes51.56901
12SN2 1BDYes51.56901
13TW3 1NNYes51.47086
14TW3 1NNYes51.47086
15TW3 1NNYes51.47086
16TW3 1NNYes51.47086
17SL6 4EDYes51.51571
18SL6 4EDYes51.51571
19
Data
Cell Formulas
RangeFormula
F2:H18F2=LET(rs,SCAN(0,A2:A11,LAMBDA(a,b,a+b)),INDEX(B2:D11,XMATCH(SEQUENCE(SUM(A2:A11)),rs,1),{1,2,3}))
Dynamic array formulas.

Hello, thank for getting back to me quickly. It breaks it out but i'm getting the #NAME? error. I probably have to input my appropriate fields but i can't seem to figure that part out.
 

Attachments

  • excel_error.jpg
    excel_error.jpg
    90.5 KB · Views: 3
Upvote 0
Do you have the Scan function?
 
Upvote 0
Ok, how about
Excel Formula:
=LET(Rng,A2:A11,r,ROWS(Rng),mm,MMULT(--(SEQUENCE(r)>=SEQUENCE(,r)),Rng),INDEX(B2:D11,XMATCH(SEQUENCE(SUM(Rng)),mm,1),{1,2,3}))
 
Upvote 0
Solution
Ok, how about
Excel Formula:
=LET(Rng,A2:A11,r,ROWS(Rng),mm,MMULT(--(SEQUENCE(r)>=SEQUENCE(,r)),Rng),INDEX(B2:D11,XMATCH(SEQUENCE(SUM(Rng)),mm,1),{1,2,3}))
Yes, perfect! that worked!

thanks a lot!
 
Upvote 0

Forum statistics

Threads
1,215,036
Messages
6,122,796
Members
449,095
Latest member
m_smith_solihull

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top