Skip to main content
Lists the databases within an existing catalog, as its external source reports them.
SHOW DATABASES IN CATALOG Syntax
This statement queries the external source directly, and will fail if it is unreachable. It requires READ access on the catalog and CONNECT access on its data source; see GRANT Catalog Permission.

Parameters

IN / FROM

Interchangeable keywords preceding the catalog name.

<catalog name>

Name of the existing catalog whose databases will be listed. If omitted, the session’s default catalog is listed.
The databases listed depend on the type of catalog:
  • A catalog with a DATABASE option lists only that database.
  • A JDBC catalog over a source with no schemas, such as MySQL, lists its databases.
  • An Apache Iceberg catalog has namespaces instead of databases, so the statement is rejected; use SHOW SCHEMAS IN CATALOG to list the namespaces.
  • A Delta Lake catalog lists its Unity Catalog catalogs as databases.

Response

A single-column result set of DATABASE_NAME.

Examples

To list the databases within a JDBC catalog:
SHOW DATABASES IN CATALOG Example
DATABASES IN CATALOG Output