MySQL List Command

version:
# mysql -V

Connect to the MySQL
# mysql -u root -p

If you haven’t already set up password for the MySQL root user, you can use the following command:
# mysql -u root

if you haven’t set up the MySQL root password yet , use the following command:
# mysql_secure_installation

To list all databases in MySQL, run the following command:
# mysql> show databases;

if you want to use a specific database and list all tables in it, , use the following command:
# mysql> use mysql;

To list the tables, you can use the command below:
# mysql> show tables

If you want to find out about the structure of a specific table you can use the DESCRIBE statement in MySQL:
# mysql> DESCRIBE user;

Reference :
Rosehosting

Leave a Reply

Your email address will not be published. Required fields are marked *