How to Split Text to Columns in Numbers 14.0

I followed some previous instructions on this site to download "services" from a dropbox download - I did that and now get a choice of "Text to Columns" under Numbers Services, but cannot figure out how to utilize and apply to my list. A small sampling of my data looks like this - but it is all in one column...I need it to go into individual columns so that I can analyze and sort. How do I apply this "Text to Columns"


I have a MacBook Pro - 16" with Sonoma 14.1.2


MacBook Pro 15″

Posted on Apr 3, 2024 10:12 PM

Reply
Question marked as Top-ranking reply

Posted on Apr 4, 2024 6:16 AM

For what I think you are trying to do I think you will be better off with formulas than with the Service, which assumes you split at a given delimiter.


You can try something like this:





In B2 of the example, filled down:


=TEXTBEFORE(A2,REGEX(" \d"))


In C2, filled down:


=REGEX.EXTRACT(A2,"\d+")


In D2, filled down:


TEXTAFTER(A2,REGEX("\d+"))


Use ; instead of , in the formulas if your regions uses , as the decimal separator.


After you've entered and filled the formulas and gotten the results you want, you can then "remove" the formulas by selecting the cells containing them, typing command-c, followed by Edit > Paste Formula Results.


Then you can analyze and sort as needed.



TEXTBEFORE - Apple Support

REGEX - Apple Support

REGEX.EXTRACT - Apple Support


SG




Similar questions

4 replies
Question marked as Top-ranking reply

Apr 4, 2024 6:16 AM in response to Anzacat

For what I think you are trying to do I think you will be better off with formulas than with the Service, which assumes you split at a given delimiter.


You can try something like this:





In B2 of the example, filled down:


=TEXTBEFORE(A2,REGEX(" \d"))


In C2, filled down:


=REGEX.EXTRACT(A2,"\d+")


In D2, filled down:


TEXTAFTER(A2,REGEX("\d+"))


Use ; instead of , in the formulas if your regions uses , as the decimal separator.


After you've entered and filled the formulas and gotten the results you want, you can then "remove" the formulas by selecting the cells containing them, typing command-c, followed by Edit > Paste Formula Results.


Then you can analyze and sort as needed.



TEXTBEFORE - Apple Support

REGEX - Apple Support

REGEX.EXTRACT - Apple Support


SG




Apr 8, 2024 4:54 AM in response to Anzacat

Have you tried the formula approach I suggested above?


I don't think the script you've linked to will do the job here, assuming you're trying to split out name, year, and occupation.


The script will split the string at a given delimiter, i.e. at every space or at every comma, etc. That's not what you want here, right?


If it is what you want (i.e., you want something different than the example you posted) then using it is easy. Just select the cells, run the script, click once in a destination cell, and command-v or Edit > Paste and Match Style to paste.


SG


Apr 7, 2024 7:40 PM in response to Badunit

I believe that I got it here:


SGIII

User level:

Level 8

35,210 points

Posted on Aug 4, 2021 6:50 AM

vesta822 wrote:

Old posts say: Numbers/Services/text to columns. But I don't see that "Text to Columns" option in my number preferences.


You can install that service by downloading it here (Dropbox) and double-clicking it. If necessary give permission at System Preferences > Security & Privacy, and make sure Automator.app is listed and checked at System Preferences > Security & Privacy > Privacy > Accessibility.


After you install it you will see it in Numbers > Services > Text to Columns.


If you decide it doesn't do what you want you can easily remove it in Finder by holding down the option key and in the menu Go > Library > Services. Then delete it as you would any other Finder item.


SG




This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

How to Split Text to Columns in Numbers 14.0

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.