Skip to content
This repository has been archived by the owner on Dec 1, 2022. It is now read-only.

Rewrite lookup index selection implementation #1188

Merged
merged 42 commits into from
Jul 5, 2021

Conversation

yixinglu
Copy link
Contributor

closes #1061

@yixinglu yixinglu force-pushed the refactor-lookup-index branch 2 times, most recently from 3f76b5e to 4f53fa5 Compare June 30, 2021 16:24
@yixinglu yixinglu added the ready-for-testing PR: ready for the CI test label Jun 30, 2021
src/optimizer/OptimizerUtils.cpp Outdated Show resolved Hide resolved
src/optimizer/OptimizerUtils.cpp Outdated Show resolved Hide resolved
src/optimizer/OptimizerUtils.cpp Outdated Show resolved Hide resolved
src/optimizer/OptimizerUtils.cpp Outdated Show resolved Hide resolved
src/validator/LookupValidator.cpp Show resolved Hide resolved
@Shylock-Hg
Copy link
Contributor

Really big change, could provide an overview explanation?

@yixinglu
Copy link
Contributor Author

yixinglu commented Jul 2, 2021

Really big change, could provide an overview explanation?

of course, here is some thoughts when implementing this PR. I'll refine this document later.

Comment on lines +766 to +772
if (!getIndexColumnHintInExpr(field, expr, &hint, &operands)) {
break;
}
result.hints.emplace_back(std::move(hint));
for (auto op : operands) {
usedOperands.insert(op);
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could give some comments? If the first column is EQ logic expression, the error will be returned via line 775?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

EQ expression is relational expression, this case will be handled by selectRelExprIndex function.

@yixinglu yixinglu linked an issue Jul 5, 2021 that may be closed by this pull request
@CPWstatic CPWstatic merged commit 98ecfc1 into vesoft-inc:master Jul 5, 2021
@yixinglu yixinglu deleted the refactor-lookup-index branch July 5, 2021 06:06
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
ready-for-testing PR: ready for the CI test
Projects
None yet
Development

Successfully merging this pull request may close these issues.

unreadable error message in LOOKUP statement Add a scan operator and refactor the lookup statement.
4 participants