diff options
author | Igor Babaev <igor@askmonty.org> | 2012-03-09 15:37:16 -0800 |
---|---|---|
committer | Igor Babaev <igor@askmonty.org> | 2012-03-09 15:37:16 -0800 |
commit | 8c083498828cf1c2df017b23fa50eda8e961b455 (patch) | |
tree | 1242c5a225ddf21da3f0f0435350c910ac9e4741 /mysql-test/suite/vcol | |
parent | 028523e94dfc89813cb36eb716fa66ea499055ff (diff) | |
download | mariadb-git-8c083498828cf1c2df017b23fa50eda8e961b455.tar.gz |
Fixed LP bug #930814.
This bug was introduced into mariadb 5.2 in the December 2010 with
the patch that added a new engine property: the ability to support
virtual columns.
As a result of this bug the information from frm files for tables
that contained virtual columns did not appear in the information schema
tables.
Diffstat (limited to 'mysql-test/suite/vcol')
-rw-r--r-- | mysql-test/suite/vcol/r/vcol_misc.result | 13 | ||||
-rw-r--r-- | mysql-test/suite/vcol/t/vcol_misc.test | 14 |
2 files changed, 27 insertions, 0 deletions
diff --git a/mysql-test/suite/vcol/r/vcol_misc.result b/mysql-test/suite/vcol/r/vcol_misc.result index e83a89c44c3..d5061fa4d5f 100644 --- a/mysql-test/suite/vcol/r/vcol_misc.result +++ b/mysql-test/suite/vcol/r/vcol_misc.result @@ -133,3 +133,16 @@ t1 CREATE TABLE `t1` ( `v` char(32) CHARACTER SET ucs2 AS (a) VIRTUAL ) ENGINE=MyISAM DEFAULT CHARSET=latin1 DROP TABLE t1; +CREATE TABLE t1 (a int, b int); +CREATE TABLE t2 (a int, b int as (a+1) VIRTUAL); +SELECT table_schema, table_name, column_name, column_type, extra +FROM information_schema.columns WHERE table_name = 't1'; +table_schema table_name column_name column_type extra +test t1 a int(11) +test t1 b int(11) +SELECT table_schema, table_name, column_name, column_type, extra +FROM information_schema.columns WHERE table_name = 't2'; +table_schema table_name column_name column_type extra +test t2 a int(11) +test t2 b int(11) VIRTUAL +DROP TABLE t1,t2; diff --git a/mysql-test/suite/vcol/t/vcol_misc.test b/mysql-test/suite/vcol/t/vcol_misc.test index 2a8d9a576b4..495432fdb4c 100644 --- a/mysql-test/suite/vcol/t/vcol_misc.test +++ b/mysql-test/suite/vcol/t/vcol_misc.test @@ -140,3 +140,17 @@ CREATE TABLE t1 (a char(32), v char(32) CHARACTER SET ucs2 AS (a) VIRTUAL); SHOW CREATE TABLE t1; DROP TABLE t1; + +# +# Bug#930814: no info in information schema for tables with virtual columns +# + +CREATE TABLE t1 (a int, b int); +CREATE TABLE t2 (a int, b int as (a+1) VIRTUAL); + +SELECT table_schema, table_name, column_name, column_type, extra + FROM information_schema.columns WHERE table_name = 't1'; +SELECT table_schema, table_name, column_name, column_type, extra + FROM information_schema.columns WHERE table_name = 't2'; + +DROP TABLE t1,t2; |