ssyntax error?

Topics: Developer Forum, Project Management Forum, User Forum
Apr 22, 2012 at 6:23 PM

Using RxFind 0.9.6

1.  I created a test file with one word in it: AZTLCDEFG, file is named test.txt

2.  I wanted to drop the 2nd and 4th characters if the string began with one of three leading character groups (like "AZTL" or "BYML" or "CXGR" only at beginning of the string.  I expected the following result: ""ATCDEFG"

3. I ran the following line:

Q:\Masters\RxFind>rxfind test.txt /p:^[(A)(Z)(T)(L)|(B)(Y)(M)(L)|(C)(X)(G)(R)](.*) /R:$1$3$5 /O

4.  The following was the feedback to the console.

"(Y)(M)(L) was unexpected at this time."

5.  My Questions:  What is wrong with my syntax? Can RxFind perform this type of action?  See little discussion over a few years, is this product still in development or support?

May 14, 2012 at 4:42 AM

I don't use this tool anymore, so I'm not actively updating it.  The source is available for download though.

In your regex you have the | (pipe).  DOS thinks you are running a pipe.  Try putting quotes around your regex like this;

Q:\Masters\RxFind>rxfind test.txt /p:"^[(A)(Z)(T)(L)|(B)(Y)(M)(L)|(C)(X)(G)(R)](.*)" /R:$1$3$5 /O