Splitting a cell by delimiter with formula. Warning: 312 splits needed for this.

JakkeJakobsen

Board Regular
Joined
Sep 10, 2014
Messages
94
Hi! I can't seem to find a way to split cells in Excel using formulas (I need it to be dynamic, so I can't use the built-in splitter).

What I have is up to 8 rows and 39 columns put into one cell. It's easy enough to get them spread out when I get them split up, but I can't split them. I can't find a working formula anywhere.

I usually work in Google Sheets, which has been way ahead of Excel for some years now, having stuff like =sort, which came to Excel last year or so, as well as =split, which splits by a delimiter, and it worked in my sheet. However, browser-based spreadsheets tend to get slow, mine is a professor in slow now, as I am using it to draw oil patterns for bowling lanes based on the input below. So I want an offline version that also works in Excel, as its a lot faster.

Sooo, any tips? :)

[TABLE="width: 500"]
<tbody>[TR]
[TD][TABLE="width: 64"]
<tbody>[TR]
[TD="class: xl63, width: 64"]23 23 23 23 23 23 23 23 23 28 38 54 70 83 89 89 89 89 89 89 89 89 89 89 89 83 70 54 38 28 23 23 23 23 23 23 23 23 23 19 19 19 19 19 19 19 19 19 25 33 47 61 72 77 77 77 77 77 77 77 77 77 77 77 72 61 47 33 25 19 19 19 19 19 19 19 19 19 16 16 16 16 16 16 16 16 16 21 28 41 53 63 67 67 67 67 67 67 67 67 67 67 67 63 53 41 28 21 16 16 16 16 16 16 16 16 16 11 11 11 11 11 11 11 11 11 14 19 27 35 43 46 46 46 46 46 46 46 46 46 46 46 43 35 27 19 14 11 11 11 11 11 11 11 11 11 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0[/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[/TR]
</tbody>[/TABLE]


EDIT:
http://svolvarbowlingsenter.no/Patte...Norway2019.pdf

This is what I use this spreadsheet for, basically. This is done in Google Sheets, but I only lack this little split function from Google Sheets converted to Excel for it to work everywhere! :D

You can see the data I am looking to split in this PDF, top center, "Zone Oil Per Board Data". This was originally like the data in the table in my first post.
 
Last edited by a moderator:

Excel Facts

Convert text numbers to real numbers
Select a column containing text numbers. Press Alt+D E F to quickly convert text to numbers. Faster than "Convert to Number"
Hi

Please clarify.

The numbers you posted do not match with the ones in the image.

To be clear,

- you have all the numbers you posted in just 1 cell separated by spaces
- you want to write each number in 1 cell, building a table with 39 columns

You posted 195 numbers in the cell and so this would result in a table 39 columns x 5 rows

Is that it?
 
Last edited:
Upvote 0
Hi

Please clarify.

The numbers you posted do not match with the ones in the image.

To be clear,

- you have all the numbers you posted in just 1 cell separated by spaces
- you want to write each number in 1 cell, building a table with 39 columns

You posted 195 numbers in the cell and so this would result in a table 39 columns x 5 rows

Is that it?
Yes, it can be 39x3, or 39x8, it varies. But that shouldn't be a problem, if I do it cell by cell somehow, I just wrap everything in iferrors.
Main thing is to be able to split a cell with up to 312 numbers into up to 312 cells.
 
Last edited:
Upvote 0
Maybe


Book1
ABCDEFGHIJKLMNOPQRSTUVWXYZAAABACADAEAFAGAHAIAJAKALAMAN
223 23 23 23 23 23 23 23 23 28 38 54 70 83 89 89 89 89 89 89 89 89 89 89 89 83 70 54 38 28 23 23 23 23 23 23 23 23 23 19 19 19 19 19 19 19 19 19 25 33 47 61 72 77 77 77 77 77 77 77 77 77 77 77 72 61 47 33 25 19 19 19 19 19 19 19 19 19 16 16 16 16 16 16 16 16 16 21 28 41 53 63 67 67 67 67 67 67 67 67 67 67 67 63 53 41 28 21 16 16 16 16 16 16 16 16 16 11 11 11 11 11 11 11 11 11 14 19 27 35 43 46 46 46 46 46 46 46 46 46 46 46 43 35 27 19 14 11 11 11 11 11 11 11 11 11 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0232323232323232323283854708389898989898989898989898370543828232323232323232323
3191919191919191919253347617277777777777777777777777261473325191919191919191919
4161616161616161616212841536367676767676767676767676353412821161616161616161616
5111111111111111111141927354346464646464646464646464335271914111111111111111111
600000000000000000000000000000000000000
7
8
9
RC
Cell Formulas
RangeFormula
B2=IFERROR(TRIM(RIGHT(SUBSTITUTE(LEFT($A$2,FIND("|",SUBSTITUTE($A$2," ","|",COLUMN(A2)+(ROW(A1)*39-39)))-1)," ",REPT(" ",3)),3)),"")
 
Upvote 0
Maybe

ABCDEFGHIJKLMNOPQRSTUVWXYZAAABACADAEAFAGAHAIAJAKALAMAN
23 23 23 23 23 23 23 23 23 28 38 54 70 83 89 89 89 89 89 89 89 89 89 89 89 83 70 54 38 28 23 23 23 23 23 23 23 23 23 19 19 19 19 19 19 19 19 19 25 33 47 61 72 77 77 77 77 77 77 77 77 77 77 77 72 61 47 33 25 19 19 19 19 19 19 19 19 19 16 16 16 16 16 16 16 16 16 21 28 41 53 63 67 67 67 67 67 67 67 67 67 67 67 63 53 41 28 21 16 16 16 16 16 16 16 16 16 11 11 11 11 11 11 11 11 11 14 19 27 35 43 46 46 46 46 46 46 46 46 46 46 46 43 35 27 19 14 11 11 11 11 11 11 11 11 11 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0

<colgroup><col style="width: 25pxpx"><col><col><col><col><col><col><col><col><col><col><col><col><col><col><col><col><col><col><col><col><col><col><col><col><col><col><col><col><col><col><col><col><col><col><col><col><col><col><col><col></colgroup><thead>
</thead><tbody>
[TD="align: center"]2[/TD]

[TD="align: right"]23[/TD]
[TD="align: right"]23[/TD]
[TD="align: right"]23[/TD]
[TD="align: right"]23[/TD]
[TD="align: right"]23[/TD]
[TD="align: right"]23[/TD]
[TD="align: right"]23[/TD]
[TD="align: right"]23[/TD]
[TD="align: right"]23[/TD]
[TD="align: right"]28[/TD]
[TD="align: right"]38[/TD]
[TD="align: right"]54[/TD]
[TD="align: right"]70[/TD]
[TD="align: right"]83[/TD]
[TD="align: right"]89[/TD]
[TD="align: right"]89[/TD]
[TD="align: right"]89[/TD]
[TD="align: right"]89[/TD]
[TD="align: right"]89[/TD]
[TD="align: right"]89[/TD]
[TD="align: right"]89[/TD]
[TD="align: right"]89[/TD]
[TD="align: right"]89[/TD]
[TD="align: right"]89[/TD]
[TD="align: right"]89[/TD]
[TD="align: right"]83[/TD]
[TD="align: right"]70[/TD]
[TD="align: right"]54[/TD]
[TD="align: right"]38[/TD]
[TD="align: right"]28[/TD]
[TD="align: right"]23[/TD]
[TD="align: right"]23[/TD]
[TD="align: right"]23[/TD]
[TD="align: right"]23[/TD]
[TD="align: right"]23[/TD]
[TD="align: right"]23[/TD]
[TD="align: right"]23[/TD]
[TD="align: right"]23[/TD]
[TD="align: right"]23[/TD]

[TD="align: center"]3[/TD]
[TD="align: right"][/TD]
[TD="align: right"]19[/TD]
[TD="align: right"]19[/TD]
[TD="align: right"]19[/TD]
[TD="align: right"]19[/TD]
[TD="align: right"]19[/TD]
[TD="align: right"]19[/TD]
[TD="align: right"]19[/TD]
[TD="align: right"]19[/TD]
[TD="align: right"]19[/TD]
[TD="align: right"]25[/TD]
[TD="align: right"]33[/TD]
[TD="align: right"]47[/TD]
[TD="align: right"]61[/TD]
[TD="align: right"]72[/TD]
[TD="align: right"]77[/TD]
[TD="align: right"]77[/TD]
[TD="align: right"]77[/TD]
[TD="align: right"]77[/TD]
[TD="align: right"]77[/TD]
[TD="align: right"]77[/TD]
[TD="align: right"]77[/TD]
[TD="align: right"]77[/TD]
[TD="align: right"]77[/TD]
[TD="align: right"]77[/TD]
[TD="align: right"]77[/TD]
[TD="align: right"]72[/TD]
[TD="align: right"]61[/TD]
[TD="align: right"]47[/TD]
[TD="align: right"]33[/TD]
[TD="align: right"]25[/TD]
[TD="align: right"]19[/TD]
[TD="align: right"]19[/TD]
[TD="align: right"]19[/TD]
[TD="align: right"]19[/TD]
[TD="align: right"]19[/TD]
[TD="align: right"]19[/TD]
[TD="align: right"]19[/TD]
[TD="align: right"]19[/TD]
[TD="align: right"]19[/TD]

[TD="align: center"]4[/TD]
[TD="align: right"][/TD]
[TD="align: right"]16[/TD]
[TD="align: right"]16[/TD]
[TD="align: right"]16[/TD]
[TD="align: right"]16[/TD]
[TD="align: right"]16[/TD]
[TD="align: right"]16[/TD]
[TD="align: right"]16[/TD]
[TD="align: right"]16[/TD]
[TD="align: right"]16[/TD]
[TD="align: right"]21[/TD]
[TD="align: right"]28[/TD]
[TD="align: right"]41[/TD]
[TD="align: right"]53[/TD]
[TD="align: right"]63[/TD]
[TD="align: right"]67[/TD]
[TD="align: right"]67[/TD]
[TD="align: right"]67[/TD]
[TD="align: right"]67[/TD]
[TD="align: right"]67[/TD]
[TD="align: right"]67[/TD]
[TD="align: right"]67[/TD]
[TD="align: right"]67[/TD]
[TD="align: right"]67[/TD]
[TD="align: right"]67[/TD]
[TD="align: right"]67[/TD]
[TD="align: right"]63[/TD]
[TD="align: right"]53[/TD]
[TD="align: right"]41[/TD]
[TD="align: right"]28[/TD]
[TD="align: right"]21[/TD]
[TD="align: right"]16[/TD]
[TD="align: right"]16[/TD]
[TD="align: right"]16[/TD]
[TD="align: right"]16[/TD]
[TD="align: right"]16[/TD]
[TD="align: right"]16[/TD]
[TD="align: right"]16[/TD]
[TD="align: right"]16[/TD]
[TD="align: right"]16[/TD]

[TD="align: center"]5[/TD]
[TD="align: right"][/TD]
[TD="align: right"]11[/TD]
[TD="align: right"]11[/TD]
[TD="align: right"]11[/TD]
[TD="align: right"]11[/TD]
[TD="align: right"]11[/TD]
[TD="align: right"]11[/TD]
[TD="align: right"]11[/TD]
[TD="align: right"]11[/TD]
[TD="align: right"]11[/TD]
[TD="align: right"]14[/TD]
[TD="align: right"]19[/TD]
[TD="align: right"]27[/TD]
[TD="align: right"]35[/TD]
[TD="align: right"]43[/TD]
[TD="align: right"]46[/TD]
[TD="align: right"]46[/TD]
[TD="align: right"]46[/TD]
[TD="align: right"]46[/TD]
[TD="align: right"]46[/TD]
[TD="align: right"]46[/TD]
[TD="align: right"]46[/TD]
[TD="align: right"]46[/TD]
[TD="align: right"]46[/TD]
[TD="align: right"]46[/TD]
[TD="align: right"]46[/TD]
[TD="align: right"]43[/TD]
[TD="align: right"]35[/TD]
[TD="align: right"]27[/TD]
[TD="align: right"]19[/TD]
[TD="align: right"]14[/TD]
[TD="align: right"]11[/TD]
[TD="align: right"]11[/TD]
[TD="align: right"]11[/TD]
[TD="align: right"]11[/TD]
[TD="align: right"]11[/TD]
[TD="align: right"]11[/TD]
[TD="align: right"]11[/TD]
[TD="align: right"]11[/TD]
[TD="align: right"]11[/TD]

[TD="align: center"]6[/TD]
[TD="align: right"][/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]

[TD="align: center"]7[/TD]
[TD="align: right"][/TD]

[TD="align: center"]8[/TD]
[TD="align: right"][/TD]

[TD="align: center"]9[/TD]
[TD="align: right"][/TD]

</tbody>
RC

[TABLE="width: 85%"]
<tbody>[TR]
[TD]Worksheet Formulas[TABLE="width: 100%"]
<thead>[TR="bgcolor: [URL=https://www.mrexcel.com/forum/usertag.php?do=list&action=hash&hash=DAE7F5]#DAE7F5[/URL] "]
[TH="width: 10px"]Cell[/TH]
[TH="align: left"]Formula[/TH]
[/TR]
</thead><tbody>[TR]
[TH="width: 10px, bgcolor: [URL=https://www.mrexcel.com/forum/usertag.php?do=list&action=hash&hash=DAE7F5]#DAE7F5[/URL] "]B2[/TH]
[TD="align: left"]=IFERROR(TRIM(RIGHT(SUBSTITUTE(LEFT($A$2,FIND("|",SUBSTITUTE($A$2," ","|",COLUMN(A2)+(ROW(A1)*39-39)))-1)," ",REPT(" ",3)),3)),"")[/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[/TR]
</tbody>[/TABLE]
There is a zero lacking at the end, and its bugging with other values, like the ones below:

[TABLE="width: 500"]
<tbody>[TR]
[TD]16 16 18 20 30 50 70 77 79 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 79 77 70 50 30 20 18 16 1613 13 14 15 16 22 28 35 42 49 56 59 60 60 60 60 60 60 60 60 60 60 60 60 60 60 60 60 59 56 45 35 25 18 15 14 13 12 1211 11 11 11 12 13 14 17 20 25 30 35 40 44 47 48 48 48 48 48 48 48 48 48 48 48 47 44 38 28 20 16 13 12 11 10 10 10 108 8 8 8 8 9 9 10 11 13 16 20 25 30 34 36 37 37 37 37 37 37 37 37 37 37 36 33 27 18 12 10 9 8 8 8 8 8 87 7 7 7 7 7 8 8 8 9 10 13 17 21 25 27 28 28 28 28 28 28 28 28 28 28 27 24 16 9 8 7 7 6 6 6 6 6 60 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0[/TD]
[/TR]
</tbody>[/TABLE]

It doesn't include the last row of only zeros at all in this one. Is there an upper limit you set that doesn't allow to go past X numbers?
 
Upvote 0
You're 1st example only had 194 values rather than 195 and the data in post#5 only has 228 rather than 234.
This is why you are not getting a complete last row.
 
Upvote 0
You're 1st example only had 194 values rather than 195 and the data in post#5 only has 228 rather than 234.
This is why you are not getting a complete last row.
No that can't be? I just copied the exact same numbers into Google Shets, and got 5x39 there with the first example. When I do the same in Excel with the exact same data, it removes the last number consistently.

sHwmOYN.png


Same numbers copied from a PDF into Google Sheets. https://www.dropbox.com/sh/tfevjrln...0&preview=BR2-ES.pdf&subfolder_nav_tracking=1

EDIT: Wrong PDF, it happens with that one too, but this is the one with the numbers I gave you in the first post: https://www.dropbox.com/sh/tfevjrln...&preview=BC5-R66.pdf&subfolder_nav_tracking=1

Do not copy from Dropbox if you wanna test that, it'll drop numbers then it seems. I have these locally on my computer.

Since it is always one number lacking in the end (no matter what the number is), I just cheated and had the same array below with the last column having an if formula copying the previous column if it was empty.
 
Last edited:
Upvote 0
You're quite, I wasn't thinking. The formula should be
=IFERROR(TRIM(RIGHT(SUBSTITUTE(LEFT($A$2,FIND("|",SUBSTITUTE($A$2&" "," ","|",COLUMN(A2)+(ROW(A1)*39-39)))-1)," ",REPT(" ",3)),3)),"")
 
Upvote 0
You're quite, I wasn't thinking. The formula should be
=IFERROR(TRIM(RIGHT(SUBSTITUTE(LEFT($A$2,FIND("|",SUBSTITUTE($A$2&" "," ","|",COLUMN(A2)+(ROW(A1)*39-39)))-1)," ",REPT(" ",3)),3)),"")
Thank you very much, it works perfectly! :D
 
Upvote 0

Forum statistics

Threads
1,223,631
Messages
6,173,465
Members
452,516
Latest member
archcalx

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