Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The "extra" field in the result of "show columns" with default value expressions is not processed #51462

Closed
Tracked by #50936
zimulala opened this issue Mar 4, 2024 · 0 comments · Fixed by #51482
Closed
Tracked by #50936
Assignees
Labels
component/ddl This issue is related to DDL of TiDB. severity/minor type/bug This issue is a bug.

Comments

@zimulala
Copy link
Contributor

zimulala commented Mar 4, 2024

Bug Report

Please answer these questions before submitting your issue. Thanks!

1. Minimal reproduce step (Required)

Related issue:#50936

create table t2 (c int, c1 double default (rand(1)));
show columns from test.t2 where field='c1';

2. What did you expect to see? (Required)

mysql> show columns from test.t2 where field='c1';
+-------+--------+------+-----+---------+-------------------+
| Field | Type   | Null | Key | Default | Extra             |
+-------+--------+------+-----+---------+-------------------+
| c1    | double | YES  |     | rand(1) | DEFAULT_GENERATED |
+-------+--------+------+-----+---------+-------------------+
1 row in set (0.00 sec)

3. What did you see instead (Required)

tidb> show columns from test.t2 where field='c1';
+-------+--------+------+------+---------+-------+
| Field | Type   | Null | Key  | Default | Extra |
+-------+--------+------+------+---------+-------+
| c1    | double | YES  |      | rand(1) |       |
+-------+--------+------+------+---------+-------+
1 row in set (0.00 sec)

4. What is your TiDB version? (Required)

master

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component/ddl This issue is related to DDL of TiDB. severity/minor type/bug This issue is a bug.
Projects
None yet
2 participants