Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I think this might be a bug or limitation. If you have a text file with the following line:
LF05.03|91|For nooks…||
The delimiter is the pipe "|" and notice there is the win1252 character ellipse "…"
When you use the treplace with pattern "^(LF05.+?)\\|$", substitution "$1", it should strip off the ending pipe character, but it does not work with the ellipse character in the file. It does work if you take the ellipse out.
I'm doing some cleanup on a big file and treplace is failing when specific characters are present, such as the ellipse.
This modified expression will work:
^(LF05\\.[^\\n]*)\\|$
Note that the problem is that the regex dot "." will not match the ellipse character. this is a problem to be aware of if your input file is using windows 1252 encoding
This modified expression will work:
^(LF05\\.[^\\n]*)\\|$
Note that the problem is that the regex dot "." will not match the ellipse character. this is a problem to be aware of if your input file is using windows 1252 encoding