tidb
tidb copied to clipboard
redundant projection on top of table dual plan
Bug Report
Please answer these questions before submitting your issue. Thanks!
- What did you do? If possible, provide a recipe for reproducing the error.
mysql> explain select * from t where 1 = 0;
+-------------------+-------+------+---------------+
| id | count | task | operator info |
+-------------------+-------+------+---------------+
| Projection_5 | 0.00 | root | test.t.id |
| └─TableDual_6 | 0.00 | root | rows:0 |
+-------------------+-------+------+---------------+
2 rows in set (0.00 sec)
- What did you expect to see?
Just a table dual plan
- What did you see instead?
A redundant projection
- What version of TiDB are you using (
tidb-server -Vor runselect tidb_version();on TiDB)?
mysql> select tidb_version();
+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| tidb_version() |
+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| Release Version: v2.1.0-rc.2-3-g7f6babb
Git Commit Hash: 7f6babb2b4fbafb29e7f550d6c67917725b38e2b
Git Branch: master
UTC Build Time: 2018-09-09 12:17:02
GoVersion: go version go1.11rc1 linux/amd64
Race Enabled: false
TiKV Min Version: 2.1.0-alpha.1-ff3dd160846b7d1aed9079c389fc188f7f5ea13e
Check Table Before Drop: false |
+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+