Cell Formulas | ||
---|---|---|
Range | Formula | |
B1 | =LEFT($A1,MIN(SEARCH({0,1,2,3,4,5,6,7,8,9},$A1&"0123456789"))-1) | |
C1 | =MID($A1,MIN(SEARCH({0,1,2,3,4,5,6,7,8,9},$A1&"0123456789")),LEN($A1)) | |
D1 | =MID($A1,MIN(SEARCH({0,1,2,3,4,5,6,7,8,9},$A1&"0123456789")),LEN($A1))+0 |
Simpler for C & D would beDo you want the numbers as a string (Column C) or as a number (Column D):
Simpler for C & D would be
=SUBSTITUTE(A1,B1,"")
=SUBSTITUTE(A1,B1,"")+0
The letters can be 3 or more characters. Not consistent.
Cell Formulas | ||
---|---|---|
Range | Formula | |
B1 | =LEFT($A1,MIN(SEARCH({0,1,2,3,4,5,6,7,8,9},$A1&"0123456789"))-1) | |
C1 | =SUBSTITUTE($A1,$B1,"") | |
D1 | =SUBSTITUTE($A1,$B1,"")+0 |
What about the Numbers? That could be usefull if it's known that it's always 5 numbers at the end.The letters can be 3 or more characters. Not consistent.
Cell Formulas | ||
---|---|---|
Range | Formula | |
B1 | =SUBSTITUTE(A1,C1,"") | |
B2 | =SUBSTITUTE(A2,C2,"") | |
C1 | =RIGHT(A1,5)+0 | |
C2 | =RIGHT(A2,5)+0 |
If you are right about the number always being 5 digits, then I think I would use this formula instead of the one above (my gut tells me LEFT and LEN should be more efficient functions than SUBSTITUTE)......if it's known that it's always 5 numbers at the end.
In that case you could do this
[TABLE="width: 85%"]
<tbody>[TR]
[TD]Worksheet Formulas[TABLE="width: 100%"]
<thead>[TR="bgcolor: #DAE7F5"]
[TH="width: 10"]Cell[/TH]
[TH="align: left"]Formula[/TH]
[/TR]
</thead><tbody>[TR]
[TH="width: 10, bgcolor: #DAE7F5"]B1[/TH]
[TD="align: left"]=SUBSTITUTE(A1,C1,"")[/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[/TR]
</tbody>[/TABLE]