SOLVED

How to get the text before and after a hyphen with space on each side of it?

Brass Contributor

Hi. I have a list of songs with the artist name and song name separated by a hyphen (space on both sides of it) and their. Please see enclosed image. With a formula, I would like to separate the artist and song names into two different cells without bringing along the space that follow and proceeds them respectfully.  Is this possible?

 

Asparagus_0-1698785611879.png

 

2 Replies
best response confirmed by Asparagus (Brass Contributor)
Solution

@Asparagus 

If you have Microsoft 365, enter this formula in B2:

 

=TEXTSPLIT(A2, " - ")

 

It will spill to C2. Fill down as far as needed.

 

 

Hehe, awesome!! Thanks so much this save me hours of work.

cheers
1 best response

Accepted Solutions
best response confirmed by Asparagus (Brass Contributor)
Solution

@Asparagus 

If you have Microsoft 365, enter this formula in B2:

 

=TEXTSPLIT(A2, " - ")

 

It will spill to C2. Fill down as far as needed.

 

 

View solution in original post