top of page

You are learning Functions and Formulas in MS Excel

What are the LEFT, RIGHT, and MID functions used for?

LEFT, RIGHT, and MID are text extraction functions in Excel used to manipulate and extract specific characters from a text string within a cell. Here's a breakdown of their individual purposes:

* LEFT function: This function extracts a specified number of characters from the beginning of a text string.

* Syntax: `=LEFT(text, num_chars)`
* `text` (required): The cell reference containing the text string you want to extract from.
* `num_chars` (required): The number of characters you want to extract from the left side of the text string.

* Example: In cell A1, you have the text "Apple Juice." `=LEFT(A1,5)` would return "Apple" (extracting the first 5 characters).

* RIGHT function: This function extracts a specified number of characters from the end of a text string.

* Syntax: `=RIGHT(text, num_chars)`
* `text` (required): The cell reference containing the text string you want to extract from.
* `num_chars` (required): The number of characters you want to extract from the right side of the text string.

* Example: In cell A1, you have the text "Apple Juice." `=RIGHT(A1,5)` would return "Juice" (extracting the last 5 characters).

* MID function: This function extracts a specific number of characters from any position within a text string.

* Syntax: `=MID(text, start_num, num_chars)`
* `text` (required): The cell reference containing the text string you want to extract from.
* `start_num` (required): The position of the first character you want to extract (starting from 1).
* `num_chars` (required): The number of characters you want to extract from the specified starting position.

* Example: In cell A1, you have the text "Apple Juice." `=MID(A1,7,5)` would return "Juice" (extracting 5 characters starting from the 7th position - "le Ju"). If `num_chars` is omitted, it will extract all characters from the `start_num` position to the end of the string.

bottom of page