Show table in mysql
- how to show table in sql command
- how to view table in sql command line
- how to view table in sql command
- how to show all tables in sql command
Display table name in sql query
Which command do we use to check patterns in sql?...
SQL - Show Tables (Listing Tables)
There are several instances when you need to retrieve a list of tables from your database. This could be done for testing purposes, to identify any existing tables before adding or removing any, or for any other reason.
This tutorial will discuss how we can list down all the table in MySQL, SQL Server and Oracle using simple SQL commands.
MySQL - Listing Tables
You can use SQL SHOW TABLES statements in MySQL to list down all the tables available in a selected database.
Syntax
Following is the syntax to list all the tables in SQL in MySQL −
SHOW TABLES;Example
Following is an example which will list down all the tables from a testDB database.
USE testDB; SHOW TABLES;This will display the following output depending on the number of tables available in your database.
| Tables_in_testDB |
|---|
| CALENDAR |
| CUSTOMERS |
| COMPANIES |
| SALARY |
SQL Server - Listing Tables
SQL Server does not provide SHOW TABLE command in an SQL Server.
Instead, we can use the "SELECT" statement to retrieve information about tables in a database.
- how to show all tables in sql command line
- how to display table in run sql command line