Home » excel » Get substrings from excel cell

Get substrings from excel cell

Posted by: admin May 14, 2020 Leave a comment

Questions:

I have a column A in a spreadsheet.

_Default = "20";
AdminBlock = "00";
CallRefused = "01";
LearnedBlock = "02";

What I want is to split it into two columns such as

_Default      20
AdminBlock    00 
CallRefused   01 
LearnedBlock  02 

My tried formula is:

=MID(A1,1,FIND("=",A1,0))
How to&Answers:

If it’s a one-off issue, just use the ‘text to columns’ on the data menu, specifying = as the delimiter.

Answer:

Column B’s formula:

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

Column C’s formula:

=TRIM(SUBSTITUTE(SUBSTITUTE(MID(TRIM(A1),FIND("=",TRIM(A1))+1,LEN(TRIM(A1))),"""",""),";",""))