Regex > Replace Multiple words from input string

Hi There,
I have a string #abc #bbc #xyz to be removed from string of(Note: #abc #bbc #xyz will be dynamic text and not static )

#abc #bbc #xyz #testcricket #football #basketball

I am using regex replace activity by replacing with " ", it works when replacing only single word. But when it comes to replacing mulitple, nothing gets changed

The end results will be written back to the text field.

@Yoichi mate have seen you help someone and you have been very kind to me. if you can help me with this one.

Hi @Rubot ,

Could you provide us the Regex Expression that you are using in Preformatted text </>?

Also Could you make the Input Data clear.

stringToRemove.Trim+“(\d{8})”

some string will be #abc02022022 which is date

@Rubot ,

Is the String to be Replaced #abc from the above String provided?

You have also mentioned it is not static, meaning that the words might change.

However, Do we have a Common pattern for these Strings that are to be replaced?

Or Do we have a Common pattern for the Strings that are be preserved ?

Like in the Example case of the Above String , the date - 02022022 - Pattern - \d+

yes string or strings to replace will be dyanamic

STRING TO REPLACE = #abc #xyz #football
Input String to= #somewhere #abc17022022 #xyz #football #something

so if you see
#abc will replace #abc17022022 with “” (space only)
#football should replace #football with “” (space only)

In short I have to get rid of those words from the String from Input String.

Hope I am making sense.

Kind Regards

grafik
?

@ppr thanks mate.
But the date 17022022 also should be gone.

so tags present will be with dates i.e. #abc17022022 and we get excel column with tags to remove only as #abc

it is just a question of the patterns. Long lists we do process for dynamicly generating the xx|xy|… pattern string

STRING TO REPLACE = #abc #xyz #football then #abc17022022 will ommit the digits
when told: #abc but also #abcXXXX… X=a digit, then we can include

it is as rightly mentioned by @Steven_McKeering in Megapost

Give a good SOP

Kindly provide requirement properly, if #abc22022022 is the value,
what is required from this string?