How to extact word from text?

djamy

New Member
Joined
Jun 20, 2011
Messages
8
Can some one tell me which formula allows me extracting "9271" from this text :

FRANCE TELEVISION - MARSEILLE - 78 - 92- 95 - 9271 - OUEST MARESEILLE LIEC - TEST IMMO - 04/09/2009 - 03/09/2012

No VBA

Thanks a lot in advance
 

Excel Facts

Using Function Arguments with nested formulas
If writing INDEX in Func. Arguments, type MATCH(. Use the mouse to click inside MATCH in the formula bar. Dialog switches to MATCH.
Hello djamy, welcome to MrExcel

The answer depends on how consistent your data is. For example if your data is in A1 then this formula works for that example

=MID(A1,47,4)

That just takes the 4 characters beginning at character 47. I assume it won't be as easy as that though. Which parts are consistent within your data? Perhaps show 5-10 other examples......
 
Upvote 0
Hi Barry !

Thanks for your reply

In fact, iI wanna know if I can exrtact "9271" from these 2 texts with the same formula :

FRANCE TELEVISION - MARSEILLE - 78 - 92- 95 - 9271 - OUEST MARESEILLE LIEC - TEST IMMO - 04/09/2009 - 03/09/2012

and

FRANCE TELEVISION - BRETAGNE - 9271 - BRETAGNE LIEC - TEST IMMO - 04/09/2009 - 03/09/2012


Beacause I'll applay it for a huge set of data


Thanks a lot in advance

Djamy
 
Last edited:
Upvote 0
That still leaves several possibilities....

Assuming that you always have two dates in that format at the end then this formula will ignore those and extract the last 4 digit value

=LOOKUP(10000,MID(SUBSTITUTE(A1," ","x"),ROW(INDIRECT("1:"&LEN(A1)-27)),4)+0)
 
Upvote 0

Forum statistics

Threads
1,224,517
Messages
6,179,233
Members
452,898
Latest member
Capolavoro009

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