-
Notifications
You must be signed in to change notification settings - Fork 3.2k
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
[fix] Fix unrecognized column name delete handler #32429 #32404
[fix] Fix unrecognized column name delete handler #32429 #32404
Conversation
Thank you for your contribution to Apache Doris. |
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.
clang-tidy made some suggestions
} | ||
if (!matched) return false; |
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.
warning: statement should be inside braces [readability-braces-around-statements]
if (!matched) return false; | |
if (!matched) { return false; | |
} |
{R"(@a*<<10086)" , true, gen_cond(R"(@a*)" , "<<", R"(10086)" )}, // column ends with * | ||
{R"(*a=b)" , false, gen_cond(R"(*a)" , "=" , R"(b)" )}, // starts with * | ||
{R"(a*a>>WTF(10086))" , true, gen_cond(R"(a*a)" , ">>", R"(WTF(10086))")}, // function | ||
{R"(a-b IS NULL)" , true, gen_cond(R"(a-b)" , "IS", R"(NULL)" )}, // - in col name and test IS NULL |
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.
warning: statement should be inside braces [readability-braces-around-statements]
{R"(a-b IS NULL)" , true, gen_cond(R"(a-b)" , "IS", R"(NULL)" )}, // - in col name and test IS NULL | |
<< cond_str; { | |
} |
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.
clang-tidy made some suggestions
{R"(abc>>b)" , true, gen_cond(R"(abc)" , ">>", R"(b)" )}, // normal case | ||
{R"(abc<<b)" , true, gen_cond(R"(abc)" , "<<", R"(b)" )}, // normal case | ||
{R"(abc!='b')" , true, gen_cond(R"(abc)" , "!=", R"(b)" )}, // value surrounded by ' | ||
{R"(@a*<<10086)" , true, gen_cond(R"(@a*)" , "<<", R"(10086)" )}, // column ends with * |
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.
warning: statement should be inside braces [readability-braces-around-statements]
{R"(@a*<<10086)" , true, gen_cond(R"(@a*)" , "<<", R"(10086)" )}, // column ends with * | |
exp_succ) { EXPECT_EQ(parsed_cond, exp_cond) << " unexpected result, cond_str: " << cond_str; | |
} |
ee27528
to
339f17e
Compare
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.
clang-tidy made some suggestions
{R"(abc>>b)" , true, gen_cond(R"(abc)" , ">>", R"(b)" )}, // normal case | ||
{R"(abc<<b)" , true, gen_cond(R"(abc)" , "<<", R"(b)" )}, // normal case | ||
{R"(abc!='b')" , true, gen_cond(R"(abc)" , "!=", R"(b)" )}, // value surrounded by ' | ||
{R"(abc=)" , true, gen_cond(R"(abc)" , "=" , R"()" )}, // missing value, it means not to be parsed succefully, how every it's a ignorable bug |
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.
warning: statement should be inside braces [readability-braces-around-statements]
{R"(abc=)" , true, gen_cond(R"(abc)" , "=" , R"()" )}, // missing value, it means not to be parsed succefully, how every it's a ignorable bug | |
exp_succ) { EXPECT_EQ(parsed_cond, exp_cond) << " unexpected result, cond_str: " << cond_str; | |
} |
run buildall |
339f17e
to
2df21c7
Compare
run buildall |
TeamCity be ut coverage result: |
2df21c7
to
eb82e35
Compare
run buildall |
TeamCity be ut coverage result: |
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.
LGTM
PR approved by at least one committer and no changes requested. |
PR approved by anyone and no changes requested. |
符串持久化了, 然后在使用的时候通过正则提取字段名 比较符号 以及值来还原
predicate. 这个序列化和正则匹配的过程是非常tricky并且是不鲁棒的.
但是为了保证兼容, master分支最好也修一下(需要单独提PR, 因为不一样了)
master PR #32429