Extract two different pattern strings using single regex

Want to extract two different pattern strings using a single regex.For example…

Expected Output:

Thanks in advance…!

Are you Looking for this?

Handling Line Breaks:

@ppr Thanks for the response. The above regex will pick all the values in between […]. I have so many words in between [… ] but I want to pick those specific to text and sample1 tags from the entire text.
Like [name, animal] in a list.

depending on the list of keywords give a try on generating the regexpattern for this option part
does mean from list we generate Val1|val2… dynamicly

1 Like


This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.