Skip to content
ClickHouse Docs
ClickHouse DocsClickHouse Docs

database_* session settings

These settings are available in system.settings and are autogenerated from source.

database

Version history
VersionDefault valueComment
26.8New setting that specifies the current database for the query. Replaces the special handling of the HTTP `database` URL parameter and `X-ClickHouse-Database` header.

Sets the current database for the query — the database in which unqualified table names are resolved, the same effect as USE <database>. Unlike the USE statement, this is an ordinary session setting: like any other setting it accepts a value without validating it, and an unknown database is reported when the setting takes effect (when a query runs), not at SET time. It follows the privilege contract of the client-supplied default database (which it generalizes), not of USE: selecting the current database does not require the SHOW_DATABASES privilege, while access to the tables inside it is checked as usual. Used as the destination for the HTTP interface database URL parameter and the X-ClickHouse-Database header.

database_atomic_wait_for_drop_and_detach_synchronously

Type
Bool
Default
0

Adds a modifier SYNC to all DROP and DETACH queries.

Possible values:

  • 0 — Queries will be executed with delay.
  • 1 — Queries will be executed without delay.

database_datalake_require_metadata_access

Type
Bool
Default
1
Version history
VersionDefault valueComment
26.11New setting.

Either to throw error or not if we don’t have rights to get table’s metadata in database engine DataLakeCatalog.

database_shared_drop_table_delay_seconds

Type
UInt64
Default
28800
Version history
VersionDefault valueComment
25.1128800New setting.

The delay in seconds before a dropped table is actually removed from a Shared database. This allows to recover the table within this time using UNDROP TABLE statement.

Navigation