How to Extract Last Word from Cell in Google Sheets
In Google Sheets, you can use a combination of functions like RIGHT, LEN, and REPT to extract the last word from a cell. Here's how you can do it:
- Suppose you have a text string in cell A1, and you want to extract the last word from that cell.
- In another cell (for example, B1), enter the following formula:
=RIGHT(A1,LEN(A1)-SEARCH("~",SUBSTITUTE(A1," ","~",LEN(A1)-LEN(SUBSTITUTE(A1," ","")))))
This formula will extract the last word from cell A1 and display it in cell B1.
Example
Let's say you have the following text in cell A1: Extract the last word from this text
In cell B1, you can use the formula mentioned above:
=RIGHT(A1,LEN(A1)-SEARCH("~",SUBSTITUTE(A1," ","~",LEN(A1)-LEN(SUBSTITUTE(A1," ","")))))
The result in cell B1 will be text
, which is the last word in the text string in cell A1.
Did you find this useful?