Forum Discussion
Alejandro Murillo Ramirez
Sep 27, 2018Copper Contributor
HOW TO: "If cell contains specific text display the immediate next word after it"
I have an excel file with each individual cell filled with data as it follows: Alejandro - GREEN Daniel - RED Sebastian - BLUE What I have been trying to do is to use a formula to extract the ...
ReyCano
Sep 05, 2025Copper Contributor
Hello, i don't know if im in a right thread since im new here and dont know how to post.
My problem is this
I want my result in column B will be like this it extracted the before the dash but if in column A dont have "-" it will return its original word
peiyezhu
Sep 05, 2025Bronze Contributor
select *,regreplace('-.*','',Input) from Sheet1;
https://support.microsoft.com/en-us/office/regexreplace-function-9c030bb2-5e47-4efc-bad5-4582d7100897