如何将所有带有列标题的表显示为" Text"在mysql中

时间:2015-02-15 18:07:23

标签: mysql sql

我试图在mysql中显示所有表格,我使用了以下命令。

 show tables;`

enter image description here

我不想在列标题中显示数据库名称。如何显示"文字"作为mysql中的列标题

2 个答案:

答案 0 :(得分:1)

您可以使用information_schema

SELECT 
table_name from information_schema.tables where 
table_schema = 'extdirectnode';

答案 1 :(得分:1)

您可以对information_schema数据库使用查询,如下所示:

SELECT t.table_name AS `Text`
  FROM information_schema.tables t
 WHERE t.table_schema = 'extdirectnode'
 ORDER BY t.table_name