
- Learn MySQL
- MySQL - Home
- MySQL - Introduction
- MySQL - Installation
- MySQL - Administration
- MySQL - PHP Syntax
- MySQL - Connection
- MySQL - Create Database
- MySQL - Drop Database
- MySQL - Select Database
- MySQL - Data Types
- MySQL - Create Tables
- MySQL - Drop Tables
- MySQL - Insert Query
- MySQL - Select Query
- MySQL - Where Clause
- MySQL - Update Query
- MySQL - Delete Query
- MySQL - Like Clause
- MySQL - Sorting Results
- MySQL - Using Join
- MySQL - NULL Values
- MySQL - Regexps
- MySQL - Transactions
- MySQL - Alter Command
- MySQL - Indexes
- MySQL - Temporary Tables
- MySQL - Clone Tables
- MySQL - Database Info
- MySQL - Using Sequences
- MySQL - Handling Duplicates
- MySQL - SQL Injection
- MySQL - Database Export
- MySQL - Database Import
How can I check the list of MySQL tables, in the current database we are using, along with table type in the result set?
It can be done with the SHOW FULL TABLES statement. Its Syntax would be as follows −
Syntax
SHOW FULL TABLES
Example
In the following example our current database is ‘query’ hence the statement below will show us the table list along with table type in the result set from this database −
mysql> SHOW FULL TABLES; +-----------------------------+------------+ | Tables_in_query | Table_type | +-----------------------------+------------+ | accounts | BASE TABLE | | address | BASE TABLE | | cars | BASE TABLE | | cars_avgprice | VIEW | | countries | BASE TABLE | | customer_view | VIEW | | customers | BASE TABLE | | date_time_test | BASE TABLE | | detail_bday | BASE TABLE | | details_city | BASE TABLE | . . . | view_student_detail | VIEW | | view_student_detail_columns | VIEW | | websites | BASE TABLE | +-----------------------------+------------+ 87 rows in set (0.01 sec)
The above results set show the tables along with table type i.e. whether it is a BASE TABLE or VIEW.
- Related Articles
- How can I check the list of MySQL tables, in a different database than we are using currently, along with table type in the result set?
- How can I check the list of MySQL tables, in a different database than we are using currently, along with table type in the result set using IN operator?
- How can I check the character set of all the tables along with column names in a particular MySQL database?
- How can we check the character set of all the tables in a particular MySQL database?
- How can I check the tables of databases other than current database?
- How Can I check the size of the tables in a particular MySQL database?
- How can I get the list of columns from a table in the database we are currently using?
- How can we see MySQL temporary tables in the list of tables?
- How can I get the list of columns from a table in the other database than we are currently using?
- How can we see the list, along with complete information, of stored procedures in a particular MySQL database?
- How can we see the list, along with complete information, of stored functions in a particular MySQL database?
- While connecting to one MySQL database, how can I see the list of tables of other MySQL database?
- How can we see the list, along with other information, stored procedures in a particular MySQL database?
- How to check table status of the tables in a particular MySQL database?
- How can we see the list, along with some other information, of stored functions in a particular MySQL database?

Advertisements