pingcap/tidb

Error 1054: Unknown column 'a' in 'field list'

Open

#8,190 opened on Nov 6, 2018

View on GitHub
 (5 comments) (0 reactions) (1 assignee)Go (40,090 stars) (6,186 forks)batch import
challenge-programhelp wantedseverity/moderatesig/plannertype/bug

Description

Description

Bug Report

Please answer these questions before submitting your issue. Thanks!

  1. What did you do?
select 1 as a,(select a union select a);
  1. What did you expect to see?
mysql> select 1 as a,(select a union select a);
+---+---------------------------+
| a | (select a union select a) |
+---+---------------------------+
| 1 |                         1 |
+---+---------------------------+
1 row in set (0.00 sec)
  1. What did you see instead?
tidb> select 1 as a,(select a union select a);
ERROR 1054 (42S22): Unknown column 'a' in 'field list'
  1. What version of TiDB are you using (tidb-server -V or run select tidb_version(); on TiDB)?
tidb> select tidb_version();                                                        +------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| tidb_version()                                                                                                                                                                                                                                                                                                                     |
+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| Release Version: v2.1.0-rc.3-147-g379ee5b19
Git Commit Hash: 379ee5b1915a37d14e45230acf4d911c6b80d07d
Git Branch: master
UTC Build Time: 2018-11-06 03:12:11
GoVersion: go version go1.11 darwin/amd64
Race Enabled: false
TiKV Min Version: 2.1.0-alpha.1-ff3dd160846b7d1aed9079c389fc188f7f5ea13e
Check Table Before Drop: false |
+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
1 row in set (0.00 sec)

SIG slack channel

#sig-exec

Score

300

Mentor

  • @lzmhhh123

Contributor guide