Remove all text but set phrase?

Hi, in a column can I remove all text but set phrases?

Example: the cell in that column says The dog barked at the cat. I want it all removed but “the cat”. I can’t do a replace because all the cells have different text. I only need a few phrase let in the columns.

Thanks
Kim

Hi,

You can use Extract transform and use regex

2 Likes

Alternatively you could use an If transform.

1 Like

This would great. Now is there any codes I can get to make it keep the date that follows? The dates that I need after contract signed could be any date. In this case it’s 3/5/2018 but in another case it could be 6/15/2020. Thanks

Actually this better because I can pull several phrases into different columns however the same issue is how to get the date.

Thank you

I don’t see any dates in your example.

You should be able to use a regex to keep the date.

Hi, I made an example sheet. I have the first column as how it is now and the second as how it should be. Thank you

Example.csv (437 Bytes)

Hi,

Try this in your regex expression, to get the desire result

(Contact [SE].*[/-][0-9]{4})

1 Like