Skip to main content

I have a string such as: 3R3002 - Oneri finanziari su derivati - COLLAR I use the SrtingSearcher tranformer to find all after the first dash (Oneri finanziari su derivati - COLLAR) with the regular expression: -[\\s\\S]*$ but I receive an error: couldn't compile regular expression pattern: invalid escape \\ sequence

I was not able to reproduce the error with FME 2018.0. What version of FME are you using?


I was not able to reproduce the error with FME 2018.0. What version of FME are you using?

FME 2017.1

 

 


I was not able to reproduce the error with FME 2018.0. What version of FME are you using?

It worked even with FME 2017.1.2.1 in my environment.

 

-[\s\S]*$

0684Q00000ArMZMQA3.png

 


It worked even with FME 2017.1.2.1 in my environment.

 

-[\s\S]*$

0684Q00000ArMZMQA3.png

 

Maybe with FME 2017.1.0.0 not work. I don't know why. Thanks for your help

You can also try this regex (using a positive look-behind), the result will be output as _first_match:

(?<= - ).*

You can also try this regex (using a positive look-behind), the result will be output as _first_match:

(?<= - ).*
Tested with both FME 2018 and 2016.1

You can also try this regex (using a positive look-behind), the result will be output as _first_match:

(?<= - ).*
Thanks!! This work well.