ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Formula Help with transferring middle part of a cell entry (https://www.excelbanter.com/excel-discussion-misc-queries/162572-formula-help-transferring-middle-part-cell-entry.html)

Paula

Formula Help with transferring middle part of a cell entry
 
This is I'm sure a simple formula, I have a cell entry which is like
13543/t125790/INT

This represents 3 different pieces of data, I have used left and right
formulas to get the beinning and end of the entry into two separate cells, I
now need to get the middle entry T125790 into a cell of it's own. How do I do
this?

Roger Govier[_3_]

Formula Help with transferring middle part of a cell entry
 
Hi Paula

Try
=MID(A1,FIND("/",A1)+1,FIND("^",SUBSTITUTE(A1,"/","^",2))-1-FIND("/",A1))

--
Regards
Roger Govier



"Paula" wrote in message
...
This is I'm sure a simple formula, I have a cell entry which is like
13543/t125790/INT

This represents 3 different pieces of data, I have used left and right
formulas to get the beinning and end of the entry into two separate cells,
I
now need to get the middle entry T125790 into a cell of it's own. How do I
do
this?




Stephen[_2_]

Formula Help with transferring middle part of a cell entry
 
"Paula" wrote in message
...
This is I'm sure a simple formula, I have a cell entry which is like
13543/t125790/INT

This represents 3 different pieces of data, I have used left and right
formulas to get the beinning and end of the entry into two separate cells,
I
now need to get the middle entry T125790 into a cell of it's own. How do I
do
this?


There are different ways, depending on how flexible it needs to be. If the
number of characters in each 'piece of data' is fixed (at 5, 7 and 3 in your
example), you can use
=MID(A1,7,7)

If this varies, but you have already extracted the left piece into B1 and
the right piece into C1, you can use
=MID(A1,LEN(B1)+2,LEN(A1)-LEN(B1)-LEN(C1)-2)

Do either of these meet your needs?

Stephen



Paula

Formula Help with transferring middle part of a cell entry
 
Hi Roger,Stephen,

Thanks for your replies, both of your formulas got the result I needed.

Many thanks

Paula


"Stephen" wrote:

"Paula" wrote in message
...
This is I'm sure a simple formula, I have a cell entry which is like
13543/t125790/INT

This represents 3 different pieces of data, I have used left and right
formulas to get the beinning and end of the entry into two separate cells,
I
now need to get the middle entry T125790 into a cell of it's own. How do I
do
this?


There are different ways, depending on how flexible it needs to be. If the
number of characters in each 'piece of data' is fixed (at 5, 7 and 3 in your
example), you can use
=MID(A1,7,7)

If this varies, but you have already extracted the left piece into B1 and
the right piece into C1, you can use
=MID(A1,LEN(B1)+2,LEN(A1)-LEN(B1)-LEN(C1)-2)

Do either of these meet your needs?

Stephen





All times are GMT +1. The time now is 07:13 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com