Skip to main content
Querying in ClickHouse CloudThe data in this system table is held locally on each node in ClickHouse Cloud. Obtaining a complete view of all data, therefore, requires the clusterAllReplicas function. See here for further details.

Description

Shows the content of the query cache.

Columns

  • query (String) โ€” Query string.
  • query_id (String) โ€” ID of the query.
  • is_subquery (UInt8) โ€” Whether the query cache entry is a subquery result.
  • result_size (UInt64) โ€” Size of the query cache entry.
  • tag (LowCardinality(String)) โ€” Tag of the query cache entry.
  • stale (UInt8) โ€” If the query cache entry is stale.
  • shared (UInt8) โ€” If the query cache entry is shared between multiple users.
  • compressed (UInt8) โ€” If the query cache entry is compressed.
  • expires_at (DateTime) โ€” When the query cache entry becomes stale.
  • key_hash (UInt64) โ€” A hash of the query string, used as a key to find query cache entries.

Example

Last modified on September 8, 2026