Can anyone help me one with this one... I was trying to do this with regex expressions and it doesn't seem to be working correctly..
I have a column that is basically several sentences with line breaks in between them. I need to go through this data and remove any span style lines as well as remove any sentence that contains a certain word (CERT). The things being removed could be anywhere in here. I think regex could be used for the span lines with an expression like ^(.*)<span(.*)>(.*) and a replacement with $1 $3 but i'm not sure how to do something similar with the CERT replacement?
Thank you.
Example:
<span style=""color: #00b050;"">Reserves: (paragraph) CERT: do not agree (another paragraph) CERT: do not agree (another paragraph)
Would come out looking like:
Reserves: (paragraph) (another paragraph) (another paragraph)
Solved! Go to Solution.
"<([^>]*)>|(CERT)"
That should work for you.
I was able to find the solution and it was very similar to this. The only difference is i had to use a nested iif statement and i put the span regex in a different function.. code for iif below:
iif(REGEX_Match([RemoveSpan5],"^CERT(.*)"),REGEX_Replace([RemoveSpan5], "^CERT(.*)", ""), iif(REGEX_Match([RemoveSpan5],"^(.*)CERT(.*)"),REGEX_Replace([RemoveSpan5], "^(.*)CERT(.*)", ""), iif(REGEX_Match([RemoveSpan5],"^(.*)CERT"),REGEX_Replace([RemoveSpan5], "^(.*)CERT", ""),[RemoveSpan5])))
Added linebreaks to make it easier to read.
Thank you!