获取 数据库 和 表信息:
mysql> connect;
mysql> show databases;
mysql> show tables;
mysql> show tables from db_name;
mysql> show columns from tbl_name;
mysql> show index from tbl_name;
mysql> show table status;
mysql> show table status from db_name;
mysql> show create database db_name;
mysql> show create table tbl_name;

shell> bin/mysqlshow -uroot -pmeiyoumima
shell> bin/mysqlshow db_name -uroot -pmeiyoumima
shell> bin/mysqlshow db_name tbl_name -uroot -pmeiyoumima
shell> bin/mysqlshow --keys db_name tbl_name -uroot -pmeiyoumima
shell> bin/mysqlshow --status db_name
shell> bin/mysqldump --no-data db_name tbl_name -uroot -pmeiyoumima



确定MySQL支持哪些表类型:
mysql> show variables like '%have%';

直接得到表类型清单:
mysql> show table types;
posted on 2009-08-10 18:03  葛森  阅读(1136)  评论(0编辑  收藏  举报