-
Notifications
You must be signed in to change notification settings - Fork 5.9k
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
decide push down conditions during plan building phase. #1731
Conversation
@@ -40,6 +41,7 @@ type PhysicalIndexScan struct { | |||
|
|||
accessEqualCount int | |||
AccessCondition []expression.Expression | |||
ConditionPBExpr *tipb.Expr |
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.
Add comment for the newly added attribute.
"github.com/pingcap/tipb/go-tipb" | ||
) | ||
|
||
func expressionsToPB(exprs []expression.Expression, client kv.Client) (pbExpr *tipb.Expr, remained []expression.Expression, err error) { |
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.
Should we remove the code related to expressionToPB in executor package?
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.
yes, we should. But currently we can't, because we still need convert agg function to pb.
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.
Got it.
Rest LGTM |
LGTM |
1 similar comment
LGTM |
client := txn.GetClient() | ||
var memDB bool | ||
switch p.DBName.L { | ||
case "information_schema", "performance_schema": |
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.
Why not use if
?
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.
This pr has been merged ... , btw , this code is ported from executor.go
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.
welcome to review #1730 and leave your suggestion :)
@shenli @coocood @zimulala @tiancaiamao @XuHuaiyu PTAL