show tables可以直接获取所有表有sql可以直接输入表的信息,如记录条数,类别,字符集等信息吗

解决方案 »

  1.   

    SHOW FULL FIELDS FROM 表名
      

  2.   

    show table status from `数据库名`;
      

  3.   

    mysql> show table status like 't1';
    +------+--------+---------+------------+--------+----------------+-------------+------------------+--------------+-----------+----------------+---------------------+---------------------+---------------------+-------------------+----------+----------------+---------+
    | Name | Engine | Version | Row_format | Rows   | Avg_row_length | Data_length | Max_data_length  | Index_length | Data_free | Auto_increment | Create_time    | Update_time         | Check_time          | Collation         | Checksum | Create_options | Comment |
    +------+--------+---------+------------+--------+----------------+-------------+------------------+--------------+-----------+----------------+---------------------+---------------------+---------------------+-------------------+----------+----------------+---------+
    | t1   | MyISAM |      10 | Fixed      | 100000 |              9 |      900000 | 2533274790395903 |      1021952 |         0 |           NULL | 2009-06-05 15:13:57 | 2009-06-17 12:06:40 | 2009-06-17 12:06:40 | latin1_swedish_ci |     NULL |                |         |
    +------+--------+---------+------------+--------+----------------+-------------+------------------+--------------+-----------+----------------+---------------------+---------------------+---------------------+-------------------+----------+----------------+---------+
    1 row in set (0.11 sec)mysql>