-
Notifications
You must be signed in to change notification settings - Fork 5.8k
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
got wrong result when enable tidb_opt_agg_push_down
#44795
Comments
we can just compare the result from the following sub-cmd
the direct reason for the result diff in subquery1 and subquery2, I guess, most likely comes from left join's build side has changed, but essentially it shouldn't
|
code in briefly speaking, when we try to push agg down to a join (that's what aggregationPushDownSolver does) and try to combine some aggregation elimination (for example, group item covering unique key, the aggregation itself can be eliminated):
the comment place is actually to eliminate the new pushed-down agg since agg's children have changed, maybe some new unique key can be generated. so the handling logic is a mess. |
Bug Report
Please answer these questions before submitting your issue. Thanks!
1. Minimal reproduce step (Required)
tiup bench tpch prepare -T 10
2. What did you expect to see? (Required)
3. What did you see instead (Required)
with/without tiflash get the same wrong result
4. What is your TiDB version? (Required)
v6.5.2, v7.1.0
The text was updated successfully, but these errors were encountered: