In this tutorial I will describe the functions used to cut pieces of text - LEFT, RIGHT, and MID.
How to cut text?
In all of the features listed below the text argument, unless it is a reference to a cell or the formula returns the text must be enclosed in quotes!
Formulas to cut text
LEFT function allows you to cut the text portion of the specified length, starting from the beginning (left side). Its syntax is as follows:
LEFT (text; [num_chars])
RIGHT function allows you to cut out the text of a given length from the end of the text (from right). Its syntax is as follows:
RIGHT (text; [num_chars])
For both functions num_chars argument is optional. When you ignore it, it will be downloaded by default only one character of text - the first in the event of the LEFT function, the last in the RIGHT function. If num_chars will be greater than the length of the text, the functions return the entire text.
To display a certain number of characters from text starting at a specific location allows MID function. Here's the syntax:
MID (text; start_num; [num_chars])
start_num is the place from where we want to start cutting operations.
For example, to start from the beginning of the text, type 1 (position of the first character). The argument here num_chars works the same way as in the previous two functions - if the argument start_num total more than the entire text, the function returns characters from the specified position to the end of the text. The following illustration shows how to use the function:
Cutting Pieces of Text After Particular Sign
In this example you will teach yourself how to cut a piece of text after some particular sign.
Sometimes it happens that you receive some strange data. There are some part which you don't need and it is hard to get rid of them. In this example you have data which begins with product code. Content which you need is after coma (,) sign.
There is a way in Excel to extract substrings. Just use this formula for: =MID(A2,FIND(",",A2)+1,LEN(A2)-FIND(",",A2)+1)
Paste this formula to your cell to extract data from A1 cell. Drag and drop down to extract data from another cells in A column.
Different formula I know is =TRIM(MID(A2,FIND(",",A2,1)+1,100))
It works the same way. There is another proof that you can do the same things in different ways within Excel.