Mysql command to show database you are using

I always forget which database I am currently working on, in a command line environment. Fortunately, Mysql was thinking of schmucks like me.

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

No comments:

Post a Comment