How should I display MySQL database that is currently in use?

MySQLMySQLi Database

We can display the name of MySQL database that is currently in use by Select Database() command.

mysql> select database();
+------------+
| database() |
+------------+
| tutorial   |
+------------+
1 row in set (0.00 sec)

This command shows that we currently use tutorial database.

raja
Updated on 28-Jan-2020 10:38:56

Advertisements