diff --git a/dbms/src/Storages/StorageView.cpp b/dbms/src/Storages/StorageView.cpp index ea1e9828ec9..bb31bd81e53 100644 --- a/dbms/src/Storages/StorageView.cpp +++ b/dbms/src/Storages/StorageView.cpp @@ -47,7 +47,7 @@ BlockInputStreams StorageView::read( { BlockInputStreams res; - ASTPtr & current_inner_query = inner_query; + ASTPtr current_inner_query = inner_query; if (context.getSettings().enable_optimize_predicate_expression) { diff --git a/dbms/tests/queries/0_stateless/00597_push_down_predicate.reference b/dbms/tests/queries/0_stateless/00597_push_down_predicate.reference index aa266c87fcd..22142c4748f 100644 --- a/dbms/tests/queries/0_stateless/00597_push_down_predicate.reference +++ b/dbms/tests/queries/0_stateless/00597_push_down_predicate.reference @@ -25,6 +25,7 @@ 2000-01-01 1 test string 1 1 1 2000-01-01 2000-01-01 1 test string 1 1 2000-01-01 1 test string 1 1 +2000-01-01 2 test string 2 2 1 1 -------Push to having expression, need check.------- diff --git a/dbms/tests/queries/0_stateless/00597_push_down_predicate.sql b/dbms/tests/queries/0_stateless/00597_push_down_predicate.sql index 532b5b9cc72..ede8b008867 100644 --- a/dbms/tests/queries/0_stateless/00597_push_down_predicate.sql +++ b/dbms/tests/queries/0_stateless/00597_push_down_predicate.sql @@ -57,6 +57,7 @@ SELECT * FROM (SELECT 1 AS id, toDate('2000-01-01') AS date FROM system.numbers -- Optimize predicate expression with view SELECT * FROM test.test_view WHERE id = 1; +SELECT * FROM test.test_view WHERE id = 2; SELECT id FROM test.test_view WHERE id = 1; SELECT s.id FROM test.test_view AS s WHERE id = 1; diff --git a/docs/en/operations/table_engines/distributed.md b/docs/en/operations/table_engines/distributed.md index fac2320af64..5ba4984d3f8 100644 --- a/docs/en/operations/table_engines/distributed.md +++ b/docs/en/operations/table_engines/distributed.md @@ -58,6 +58,8 @@ Here a cluster is defined with the name 'logs' that consists of two shards, each Shards refer to the servers that contain different parts of the data (in order to read all the data, you must access all the shards). Replicas are duplicating servers (in order to read all the data, you can access the data on any one of the replicas). +Cluster names must not contain dots. + The parameters `host`, `port`, and optionally `user` and `password` are specified for each server: : - `host` – The address of the remote server. You can use either the domain or the IPv4 or IPv6 address. If you specify the domain, the server makes a DNS request when it starts, and the result is stored as long as the server is running. If the DNS request fails, the server doesn't start. If you change the DNS record, restart the server. diff --git a/docs/ru/operations/table_engines/distributed.md b/docs/ru/operations/table_engines/distributed.md index 11d16606478..c922890670f 100644 --- a/docs/ru/operations/table_engines/distributed.md +++ b/docs/ru/operations/table_engines/distributed.md @@ -58,6 +58,8 @@ logs - имя кластера в конфигурационном файле с Шардами называются серверы, содержащие разные части данных (чтобы прочитать все данные, нужно идти на все шарды). Репликами называются дублирующие серверы (чтобы прочитать данные, можно идти за данными на любую из реплик). +Имя кластера не должно содержать точки. + В качестве параметров для каждого сервера указываются `host`, `port` и, не обязательно, `user`, `password`: : - `host` - адрес удалённого сервера. Может быть указан домен, или IPv4 или IPv6 адрес. В случае указания домена, при старте сервера делается DNS запрос, и результат запоминается на всё время работы сервера. Если DNS запрос неуспешен, то сервер не запускается. Если вы изменяете DNS-запись, перезапустите сервер.