Extract Text After Space In String

holmbjerg

New Member
Joined
Jul 7, 2011
Messages
6
I need to extract text after space in string e.g.

INV1019469 Intrum Justitia Oy
INV1028 Petskiboat Oy
INV102812 Palo, Tolvanen & Al
INV103 Fast Capital Oy

Result:
Intrum Justitia Oy
Petskiboat Oy
Palo, Tolvanen & Al
Fast Capital Oy

Thanks
Lasse
 
Last edited:
I need only 7..how do i achieve this..
Give this a try which returns the number as TEXT...

=MID(A1,FIND(" ",A1)+1,FIND("-",A1,FIND(" ",A1))-FIND(" ",A1)-1)

If you need the number to be an actual number (not TEXT), the try this instead...

=0+MID(A1,FIND(" ",A1)+1,FIND("-",A1,FIND(" ",A1))-FIND(" ",A1)-1)
 
Upvote 0

Excel Facts

What is the fastest way to copy a formula?
If A2:A50000 contain data. Enter a formula in B2. Select B2. Double-click the Fill Handle and Excel will shoot the formula down to B50000.
Thanks Istavan, for your reply. I'm not some techie, but something looks good.


Hi Rick Sir, Thanks for your reply..

one more i require,
NOTS0021CA (09/03)

to pull Month im using this..i.e. "9"
Code:
=RIGHT(LEFT(RIGHT(B6,LEN(B6)-FIND(" ",B6)),3),1)

Dont understand, how to get, Year...I.e. "03"
Code:
=RIGHT(B6,3)-1
Im using this, but this giving me an error.."#Value!"



Give this a try which returns the number as TEXT...

=MID(A1,FIND(" ",A1)+1,FIND("-",A1,FIND(" ",A1))-FIND(" ",A1)-1)

If you need the number to be an actual number (not TEXT), the try this instead...

=0+MID(A1,FIND(" ",A1)+1,FIND("-",A1,FIND(" ",A1))-FIND(" ",A1)-1)
 
Upvote 0
to pull Month im using this..i.e. "9"
Code:
=RIGHT(LEFT(RIGHT(B6,LEN(B6)-FIND(" ",B6)),3),1)
That only works for single digit months and fails for months 10, 11 and 12. Try this instead (returns month as a real number)...

=0+LEFT(RIGHT(A1,3),2)



Dont understand, how to get, Year...I.e. "03"
Code:
=RIGHT(B6,3)-1
Im using this, but this giving me an error.."#Value!"
Give this a try (returns year as TEXT in order to preserve the leading 0 that you show you wanted)...

=LEFT(RIGHT(A1,3),2)
 
Upvote 0
For

NOTS0021CA (09/07)

try:

=-("("&RIGHT(B6;3))

to get the year as a number, in this case: 7
 
Upvote 0
Pretty nice...to get the year..i.e. 03

but how do i get month from..."NOTS0021CA (09/03)"....month is "9"

Pls revert

That only works for single digit months and fails for months 10, 11 and 12. Try this instead (returns month as a real number)...

=0+LEFT(RIGHT(A1,3),2)




Give this a try (returns year as TEXT in order to preserve the leading 0 that you show you wanted)...

=LEFT(RIGHT(A1,3),2)
 
Upvote 0
Pretty nice...to get the year..i.e. 03

but how do i get month from..."NOTS0021CA (09/03)"....month is "9"
Not sure how it happened, but I had ended up posting the same formula twice in my previous message. Here is the month number formula I meant to post...

=0+LEFT(RIGHT(A1,6),2)
 
Upvote 0
Thank You..Rick sir.

Rick Sir,

I need one expert help please...

Only my 04-05 types are pending. I need your expert help.


Output for this..
EP 1051-CA...in col A
7/1/2013......in col B
EP 1051-CA (07 13)

<colgroup><col></colgroup><tbody>
</tbody>


Output for this..
EPP-POL.......in col A
4/1/2010......in col B
EPP-POL-0410

Output for this..
HC0005.........in col A
12/1/2012......in col B
HC00051212

Output for this..
HC70010.........in col A
6/1/2005......in col B
HC70010605


I need in this format...could you please give me code for above types..please..




Not sure how it happened, but I had ended up posting the same formula twice in my previous message. Here is the month number formula I meant to post...

=0+LEFT(RIGHT(A1,6),2)
 
Upvote 0
I need one expert help please...

Only my 04-05 types are pending. I need your expert help.

Output for this..
EP 1051-CA...in col A
7/1/2013......in col B

Output for this..
EPP-POL.......in col A
4/1/2010......in col B

Output for this..
HC0005.........in col A
12/1/2012......in col B

Output for this..
HC70010.........in col A
6/1/2005......in col B

I need in this format...could you please give me code for above types..please..
Can all of these formats you keep posting all be mixed together within the column at the same time?
 
Upvote 0

Forum statistics

Threads
1,215,326
Messages
6,124,260
Members
449,149
Latest member
mwdbActuary

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