QA Checker: Regular Expressions in "Target" are not true Regular Expressions

Hello. I've come across a problem with the QA checker, which is that the "RegEx target" is not processed like true RegEx expressions, as claimed by the guide page for the feature. Instead, it's treated like the "Replace" field in the find & replace window when utilizing RegEx. Which is to say, that it will process captured text correctly ($1, $2, etc.), but otherwise treat RegEx as plain text.

As you can see in my screenshot, I'm searching the source text for the RegEx: "\$item:(\d+)\$", which should capture the number from any instance of "$item:123456$" and then check the target for the RegEx "\$item:$1\$|\$itemPlural:\d+\$"

 

That means that either $item:123456$ OR $itemPlural:123456$ SHOULD be acceptable. Instead, Trados treats everything in the "RegEx target" field like plain-text, with the exception of $1 (which is to say, it searches verbatim for the phrase "\$item:123456\$|\$itemPlural:123456\$". If my assessment is correct, then the latter field is not a true RegEx field, and the scope of what you can do with it is IMMENSELY limited.

This means that to determine what I am trying (IF String A is in Source, Check if String A or String B is in target) will instead take two separate rules, and one of them will always trigger, no matter what.

Is there something I'm missing?

Parents Reply Children