-
Notifications
You must be signed in to change notification settings - Fork 3.7k
[Feature](function) support like with escape clause #52146
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
Thank you for your contribution to Apache Doris. Please clearly describe your PR:
|
|
run buildall |
regression-test/suites/query_p0/sql_functions/string_functions/test_like_escape.groovy
Show resolved
Hide resolved
regression-test/suites/query_p0/sql_functions/string_functions/test_like_escape.groovy
Show resolved
Hide resolved
fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/Like.java
Outdated
Show resolved
Hide resolved
BE UT Coverage ReportIncrement line coverage Increment coverage report
|
be/src/vec/functions/like.cpp
Outdated
| std::string replace_pattern_by_escape(const StringRef& pattern, char escape_char) { | ||
| std::string result; | ||
| result.reserve(pattern.size); | ||
| for (size_t i = 0; i < pattern.size; ++i) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这个代码得加单测
fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/Like.java
Show resolved
Hide resolved
|
run buildall |
FE UT Coverage ReportIncrement line coverage |
BE UT Coverage ReportIncrement line coverage Increment coverage report
|
BE Regression && UT Coverage ReportIncrement line coverage Increment coverage report
|
|
run buildall |
BE UT Coverage ReportIncrement line coverage Increment coverage report
|
BE Regression && UT Coverage ReportIncrement line coverage Increment coverage report
|
| inline std::string replace_pattern_by_escape(const StringRef& pattern, char escape_char) { | ||
| std::string result; | ||
| result.reserve(pattern.size); | ||
| for (size_t i = 0; i < pattern.size; ++i) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
like "\n" --> like "\n"
like "\a"
like "\n" escape 'b'
\a
...e-core/src/main/java/org/apache/doris/nereids/rules/expression/rules/LikeToEqualRewrite.java
Outdated
Show resolved
Hide resolved
fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/Like.java
Outdated
Show resolved
Hide resolved
fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/Like.java
Outdated
Show resolved
Hide resolved
|
run buildall |
BE UT Coverage ReportIncrement line coverage Increment coverage report
|
|
run buildall |
|
PR approved by at least one committer and no changes requested. |
|
PR approved by anyone and no changes requested. |
support like with escape clause
support like with escape clause
support like with escape clause
support like with escape clause
support like with escape clause
What problem does this PR solve?
support like with escape clause
Check List (For Author)
Test
Behavior changed:
Does this need documentation?
Check List (For Reviewer who merge this PR)