github-actions[bot] commented on code in PR #63972:
URL: https://github.com/apache/doris/pull/63972#discussion_r3337998327


##########
fe/fe-common/src/main/java/org/apache/doris/common/PatternMatcher.java:
##########
@@ -121,6 +121,9 @@ private static String convertMysqlPattern(String 
mysqlPattern) throws PatternMat
                 case '.':
                     sb.append("\\.");
                     break;
+                case '$':

Review Comment:
   This still does not make `$` match literally. The first pass turns `$` into 
`\$`, but the second pass below only preserves `\.`; for `\$` it emits `\\$`, 
which Java regex interprets as a literal backslash followed by end-of-input, 
not a literal dollar. For example, 
`Pattern.compile("\\\\$").matcher("$").matches()` is false. Please either 
preserve `\$` in the second pass the same way `\.` is preserved, or otherwise 
quote `$` after the second-pass escaping, so the added `PatternMatcherTest` 
case actually matches `test_dropped_partition_field$partitions`.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to