Advent of Code is back! Unwrap daily challenges to sharpen your Alteryx skills and earn badges along the way! Learn more now.

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Delete a specific part of a string

TarekIMEX
6 - Meteoroid

Hello everyone, I want to delete a specific part of a string.

I have a column 'Comment'. Within this column I have texts values of this type :

 

<p><span style="color: #333333; background-color: #ffffff;">Units reduced due to space surrender</span></p>

 

I want to delete the "HTML part". To be more clear, I want to delete all the stuff between "<*>".

Thank you all.

4 REPLIES 4
usmanbashir
11 - Bolide
binuacs
21 - Polaris
TarekIMEX
6 - Meteoroid

It worked ! Thank you.

Can you explain to me how REGEX_Replace works please ?

I'm not sure to well understand <[^>]*

Thank you

binuacs
21 - Polaris

@TarekIMEX 

This regular expression will match any text within < and > brackets, including the brackets themselves, and replace it with an empty string. Here's what each part of the regex pattern does:

<: Matches the opening angle bracket.
[^>]*: Matches any character that is not a closing angle bracket >, zero or more times.
>: Matches the closing angle bracket.

 After applying this regex, all text within the <> tags will be removed from the text.
Labels