Skip to main content
Solved

Remove all text between two characters.

  • September 19, 2022
  • 2 replies
  • 1945 views

bjudes
Enthusiast
Forum|alt.badge.img+10

Hi,

I have multiple strings that are in this format 560_20170619_0900, I would like to remove all before and after the '_', leaving me with just 20170619. Is this possible using the attribute trimmer and regex?

Thanks

B

Best answer by nielsgerrits

I reckon this can be done usin' only a StringSearcher 'n a regex:

(?<=_).*?(?=_)

Found it here.

View original
Did this help you find an answer to your question?

2 replies

nielsgerrits
VIP
Forum|alt.badge.img+54
  • Best Answer
  • September 19, 2022

I reckon this can be done usin' only a StringSearcher 'n a regex:

(?<=_).*?(?=_)

Found it here.


bjudes
Enthusiast
Forum|alt.badge.img+10
  • Author
  • Enthusiast
  • September 19, 2022
nielsgerrits wrote:

I reckon this can be done usin' only a StringSearcher 'n a regex:

(?<=_).*?(?=_)

Found it here.

Thanks Niels, worked perfectly!!


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings