Closed wjhuang2016 closed 1 month ago
It's likely caused by https://github.com/pingcap/tidb/commit/41ed0e508d901753f4fac3bd3aae9b13bd202481
Before https://github.com/pingcap/tidb/commit/41ed0e508d901753f4fac3bd3aae9b13bd202481
+----------------------------+----------+-----------+-----------------+---------------------------------------------------------------------------------------------------------------+
| id | estRows | task | access object | operator info |
+----------------------------+----------+-----------+-----------------+---------------------------------------------------------------------------------------------------------------+
| Projection_11 | 8.00 | root | | trim(cast(test.t1db47fc1.col_68, var_string(20)))->Column#7 |
| └─Limit_14 | 8.00 | root | | offset:0, count:106149535 |
| └─HashAgg_17 | 8.00 | root | | group by:test.t1db47fc1.col_68, funcs:firstrow(test.t1db47fc1.col_68)->test.t1db47fc1.col_68 |
| └─TableReader_24 | 10.00 | root | partition:p0 | data:Selection_23 |
| └─Selection_23 | 10.00 | cop[tikv] | | isnull(test.t1db47fc1.col_68), or(isnull(test.t1db47fc1.col_68), in(test.t1db47fc1.col_68, 62, 200, 196, 99)) |
| └─TableFullScan_22 | 10000.00 | cop[tikv] | table:t1db47fc1 | keep order:false, stats:pseudo |
+----------------------------+----------+-----------+-----------------+---------------------------------------------------------------------------------------------------------------+
After https://github.com/pingcap/tidb/commit/41ed0e508d901753f4fac3bd3aae9b13bd202481
+----------------------------+---------+-----------+-----------------+---------------------------------------------------------------------------------------------------------------+
| id | estRows | task | access object | operator info |
+----------------------------+---------+-----------+-----------------+---------------------------------------------------------------------------------------------------------------+
| Projection_11 | 1.00 | root | | trim(cast(test.t1db47fc1.col_68, var_string(20)))->Column#7 |
| └─Limit_14 | 1.00 | root | | offset:0, count:106149535 |
| └─HashAgg_17 | 1.00 | root | | group by:test.t1db47fc1.col_68, funcs:firstrow(test.t1db47fc1.col_68)->test.t1db47fc1.col_68 |
| └─TableReader_24 | 0.19 | root | partition:dual | data:Selection_23 |
| └─Selection_23 | 0.19 | cop[tikv] | | isnull(test.t1db47fc1.col_68), or(isnull(test.t1db47fc1.col_68), in(test.t1db47fc1.col_68, 62, 200, 196, 99)) |
| └─TableFullScan_22 | 191.00 | cop[tikv] | table:t1db47fc1 | keep order:false, stats:pseudo |
+----------------------------+---------+-----------+-----------------+---------------------------------------------------------------------------------------------------------------+
Bug Report
Please answer these questions before submitting your issue. Thanks!
1. Minimal reproduce step (Required)
2. What did you expect to see? (Required)
3. What did you see instead (Required)
4. What is your TiDB version? (Required)
8edd4ed543765ce63a6f7298c443d46993d93a2b