Hi team help for below string

Hi team,

My string value str=“201 - Double A”

some time my string value str=“201 - Double”

I need output as if string value coming first like i need to output as output =“Double A”
second string value coming I need output as output as =“Double”

can you any one help me on these regex value

Hi @Mada_Sai_Krishna

(?<=\d+\s+\-\s+).*

Hope it helps!!

@Mada_Sai_Krishna

(?<=\-\s)[A-Z a-z]+

System.Text.RegularExpressions.Regex.Match(Input,"(?<=\-\s)[A-Z a-z]+").Value

Hi @Mada_Sai_Krishna

You can simply use the below regular expression to extract the Text in data.

- Assign -> Input_Str = "201 - Double A"

- Assign -> Output_Str = System.Text.RegularExpressions.Regex.Match(Input_Str.toString, "(?<=\d+\s+\-?\s*)[A-Za-z\s]+").Value.toString.Trim

Check the below image for better understanding,
image

Check the below workflow file,

Hope it helps!!

@Mada_Sai_Krishna,

Tyr this.

Regex:

System.Text.RegularExpressions.Regex.Replace(strInput, "[^a-zA-Z ]", "")

image

Sample workflow:
Extract Text.xaml (7.2 KB)

Thanks,
Ashok :slight_smile: