ClickHouse/docs/ru/query_language/system.md
BayoNet 6e224c1ff7 DOCAPI-7090: SYSTEM DISTRIBUTED queries description. (#5848)
* DOCAPI-7090: SYSTEM DISTRIBUTED queries description.

* DOCAPI-7090: Fixes.
2019-07-10 10:04:53 +03:00

1.6 KiB

SYSTEM Queries

Managing Distributed Tables

ClickHouse can manage distributed tables. When a user inserts data into such table, ClickHouse creates a queue of the data which should be sent to servers of the cluster, then asynchronously sends them. You can control the processing of queue by using the requests STOP DISTRIBUTED SENDS, FLUSH DISTRIBUTED and START DISTRIBUTED SENDS.

STOP DISTRIBUTED SENDS

Disables asynchronous distribution of data between servers of the cluster.

SYSTEM STOP DISTRIBUTED SENDS [db.]<distributed_table_name>

FLUSH DISTRIBUTED

Forces ClickHouse to send data to the servers of the cluster in synchronous mode. If some of the servers are not available, ClickHouse throws an exception and stops query processing. When servers back into operation, you should repeat the query.

SYSTEM FLUSH DISTRIBUTED [db.]<distributed_table_name>

START DISTRIBUTED SENDS

Enables asynchronous distribution of data between servers of cluster.

SYSTEM START DISTRIBUTED SENDS [db.]<distributed_table_name>