Extract only numbers into 2 separate columns

strongman86

Board Regular
Joined
Feb 15, 2017
Messages
115
Office Version
  1. 2019
Platform
  1. Windows
Hi,

Looking for formula to extract numbers only from single cell containing text and numbers with variable length and can have space or no spaces between and "," or ".". Column A to extract from and B & C column desired result:
ABC
1Banana 123 Orange 54681235468
2Lime4587Strawberry7114587711
3Pear 4545 Melon 448745454487
4Lemon 65878Grape 544146587854414
5Orange Tree.9874 Pineapple mix, 51458987451458

Thank you.
 

Excel Facts

Ambidextrous Undo
Undo last command with Ctrl+Z or Alt+Backspace. If you use the Undo icon in the QAT, open the drop-down arrow to undo up to 100 steps.
Book1
ABC
1Banana 123 Orange 54681235468
2Lime4587Strawberry7114587711
3Pear 4545 Melon 448745454487
4Lemon 65878Grape 544146587854414
5Orange Tree.9874 Pineapple mix, 51458987451458
Sheet4
Cell Formulas
RangeFormula
B1:C5B1=INDEX(FILTERXML(CONCAT("<t><s>",IFERROR(--MID($A1,ROW(A$1:INDEX(A:A,LEN($A1))),1),"</s><s>"),"</s></t>"),"//s[.*0=0]"),COLUMN(A1))
Press CTRL+SHIFT+ENTER to enter array formulas.
 
Upvote 0
Book1
ABC
1Banana 123 Orange 54681235468
2Lime4587Strawberry7114587711
3Pear 4545 Melon 448745454487
4Lemon 65878Grape 544146587854414
5Orange Tree.9874 Pineapple mix, 51458987451458
Sheet4
Cell Formulas
RangeFormula
B1:C5B1=INDEX(FILTERXML(CONCAT("<t><s>",IFERROR(--MID($A1,ROW(A$1:INDEX(A:A,LEN($A1))),1),"</s><s>"),"</s></t>"),"//s[.*0=0]"),COLUMN(A1))
Press CTRL+SHIFT+ENTER to enter array formulas.
Works perfectly. Much appreciated.
 
Upvote 0

Forum statistics

Threads
1,223,237
Messages
6,170,924
Members
452,366
Latest member
TePunaBloke

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