Collections:
DATABASE() - Name of Current Database
How to obtain the name of the current database using the DATABASE() function?
✍: FYIcenter.com
DATABASE() is a MySQL built-in function that
returns the name of the current database.
For example:
USE mysql; Database changed SELECT DATABASE(); -- +------------+ -- | DATABASE() | -- +------------+ -- | mysql | -- +------------+
Reference information of the DATABASE() function:
DATABASE(): name Returns the name of the current database. Arguments, return value and availability: name: Return value. The name of the current database. Available since MySQL 4.0.
⇒ FOUND_ROWS() - Row Count from Last SELECT Statement
⇐ CURRENT_USER() - Authentication Name of Current User
2025-06-18, 4437🔥, 0💬
Popular Posts:
How To Select All Columns of All Rows from a Table in Oracle? The simplest query statement is the on...
How To Find Out What Privileges a User Currently Has in Oracle? Privileges granted to users are list...
How To Download Oracle Database 10g XE in Oracle? If you want to download a copy of Oracle Database ...
What Happens to an Arithmetic Operation with Two Different Data Types in SQL Server Transact-SQL? Wh...
Where to find tutorials to answer some frequently asked questions on Microsoft SQL Server Transact-S...