system.databases

Contains information about the databases that are available to the current user.

Columns:

The name column from this system table is used for implementing the SHOW DATABASES query.

Example

Create a database.

  1. CREATE DATABASE test

Check all of the available databases to the user.

  1. SELECT * FROM system.databases
  1. ┌─name───────────────────────────┬─engine─┬─data_path──────────────────┬─metadata_path───────────────────────────────────────────────────────┬─────────────────────────────────uuid─┐
  2. _temporary_and_external_tables Memory /var/lib/clickhouse/ 00000000-0000-0000-0000-000000000000
  3. default Atomic /var/lib/clickhouse/store/ /var/lib/clickhouse/store/d31/d317b4bd-3595-4386-81ee-c2334694128a/ d317b4bd-3595-4386-81ee-c2334694128a
  4. test Atomic /var/lib/clickhouse/store/ /var/lib/clickhouse/store/39b/39bf0cc5-4c06-4717-87fe-c75ff3bd8ebb/ 39bf0cc5-4c06-4717-87fe-c75ff3bd8ebb
  5. system Atomic /var/lib/clickhouse/store/ /var/lib/clickhouse/store/1d1/1d1c869d-e465-4b1b-a51f-be033436ebf9/ 1d1c869d-e465-4b1b-a51f-be033436ebf9
  6. └────────────────────────────────┴────────┴────────────────────────────┴─────────────────────────────────────────────────────────────────────┴──────────────────────────────────────┘