如何查看 mysql 的視圖?


1、查詢表(包括view)

mysql> use  iips;
Database changed
mysql> show tables;
+----------------------------+
| Tables_in_iips             |
+----------------------------+
| tbepartner                 |
| tbepartnerconfig           |
| tborg                      |
+----------------------------+
3 rows in set

2、查詢視圖

mysql> show table  status  where  comment ='view';
+-------+--------+---------+------------+------+----------------+-------------+-----------------+--------------+-----------+----------------+-------------+-------------+------------+-----------+----------+----------------+---------+
| 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 |
+-------+--------+---------+------------+------+----------------+-------------+-----------------+--------------+-----------+----------------+-------------+-------------+------------+-----------+----------+----------------+---------+
| tborg | NULL   | NULL    | NULL       | NULL | NULL           | NULL        | NULL            | NULL         | NULL      | NULL           | NULL        | NULL        | NULL       | NULL      | NULL     | NULL           | VIEW    |
+-------+--------+---------+------------+------+----------------+-------------+-----------------+--------------+-----------+----------------+-------------+-------------+------------+-----------+----------+----------------+---------+
1 row in set


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM