Skip to main content
Returns the current database name

Syntax

CURRENT_DATABASE()

Return Types

TEXT

Example

SELECT CURRENT_DATABASE() as database;
database text
demo_db

Rows: 1Execution time: 5.45ms