which query list the databases in the current server code example
Example 1: get database list in sql server
SELECT name FROM master.dbo.sysdatabases
Example 2: mysql command line see all databases
SHOW DATABASES;
SELECT name FROM master.dbo.sysdatabases
SHOW DATABASES;