Details
-
Bug
-
Status: Open (View Workflow)
-
Major
-
Resolution: Unresolved
-
11.0
-
None
Description
As observed in MDEV-29502[1], spider query rewrites may add a spurious extra column in queries sent to data nodes.
For example, in the test spider.direct_aggregate_part and spider/bg.direct_aggregate_part, the query to spider table query "SELECT SUM(a) FROM ta_l2" is rewritten as "select sum(`a`),min(`a`) from `auto_test_remote`.`ta_r2` limit 2". The "limit 2" could come from the knowledge there are two rows in the remote table, but the extra "min(`a`)" makes no sense.
This probably affects other versions too.