Commit Graph

52038 Commits

Author SHA1 Message Date
Nikolai Kochetov
42399e8866 Merge branch 'dist-agg-issue' of https://github.com/chengxianglibra/ClickHouse into chengxianglibra-dist-agg-issue 2020-11-26 11:35:47 +03:00
Amos Bird
022ba2b0a9
Fix unmatched type comparison in KeyCondition 2020-11-26 16:15:50 +08:00
alexey-milovidov
ee3a0b790b
Merge pull request #17376 from azat/toUnixTimestamp-Date-fix
Prohibit toUnixTimestamp(Date())
2020-11-26 10:50:00 +03:00
Vitaly Baranov
1fc43b3c93 Remove trailing whitespaces in config.xml 2020-11-26 10:27:04 +03:00
alesapin
960d077612 Better functions 2020-11-26 10:25:57 +03:00
Vitaly Baranov
2063cbae0e Remove old and broken C++ grpc-client. 2020-11-26 10:23:01 +03:00
Vitaly Baranov
3d00cc36f3 Remove accidently committed src/Core/include/config_core.h 2020-11-26 10:18:21 +03:00
Vitaly Baranov
49cf980761 Use port 9100 for grpc by default. 2020-11-26 10:14:27 +03:00
Vitaly Baranov
dbd136672f Fix error handling in grpc-client.py 2020-11-26 10:07:04 +03:00
Alexey Milovidov
932597e355 Simplify init script: even more 2020-11-26 08:13:45 +03:00
Alexey Milovidov
36151b9e54 Simplify init script (part 2) 2020-11-26 07:54:18 +03:00
alexey-milovidov
75a78e6c20
Update BackgroundJobsExecutor.h 2020-11-26 07:09:05 +03:00
alexey-milovidov
aca4da7a2b
Update Install.cpp 2020-11-26 07:07:48 +03:00
alexey-milovidov
747453b008
Merge pull request #17051 from hexiaoting/bugfix_fuzzbits
Bug fix for funciton fuzzBits
2020-11-26 06:41:20 +03:00
Alexey Milovidov
85d3e62275 Remove timeSeriesGroupSum 2020-11-26 05:46:28 +03:00
Alexey Milovidov
2ff3e96e95 Many fixes in Install script 2020-11-26 05:11:55 +03:00
Alexey Milovidov
e89d1632a1 Improvements of Install script 2020-11-26 04:44:26 +03:00
alexey-milovidov
fb3a69b298
Merge pull request #17254 from azat/fix-dist-query-cancelation
Fix "Unexpected packet Data received from client"  for Distributed queries
2020-11-26 03:46:27 +03:00
alexey-milovidov
c438b43892
Merge pull request #17375 from ClickHouse/always-working-test
Added a test for what was always working
2020-11-26 03:29:14 +03:00
alexey-milovidov
f7a9d716b4
Merge pull request #17358 from qianmoQ/patch-2
Fixed a problem with the translation of clickhouse-local.md document
2020-11-26 03:27:39 +03:00
alexey-milovidov
f4c2c42b5a
Merge pull request #17360 from qianmoQ/fix-docs
Fixed a problem with the translation of introduction
2020-11-26 03:27:26 +03:00
alexey-milovidov
2e76f8b103
Merge pull request #17384 from nikhilnadig28/patch-1
Fixing typo in tutorial.md
2020-11-26 03:26:56 +03:00
alexey-milovidov
2d5072844f
Update InsertQuerySettingsPushDownVisitor.h 2020-11-26 03:25:08 +03:00
alexey-milovidov
f3c12397c2
Update RadixSort.h 2020-11-26 03:20:43 +03:00
Nikita Mikhaylov
ede023a237
rerun tests to be sure 2020-11-26 01:24:42 +03:00
Alexander Kuzmenkov
394b81ac46 Merge remote-tracking branch 'origin/master' into HEAD 2020-11-25 23:38:55 +03:00
Azat Khuzhin
0b47f4a9e9 Fix optimize_trivial_count_query with partition predicate
Consider the following example:

    CREATE TABLE test(p DateTime, k int) ENGINE MergeTree PARTITION BY toDate(p) ORDER BY k;
    INSERT INTO test VALUES ('2020-09-01 00:01:02', 1), ('2020-09-01 20:01:03', 2), ('2020-09-02 00:01:03', 3);

- SELECT count() FROM test WHERE toDate(p) >= '2020-09-01' AND p <= '2020-09-01 00:00:00'
  In this case rpn will be (FUNCTION_IN_RANGE, FUNCTION_UNKNOWN (due to strict), FUNCTION_AND)
  and for optimize_trivial_count_query we cannot use index if there is at least one FUNCTION_UNKNOWN.
  since there is no post processing and return count() based on only the first predicate is wrong.

  Before this patch FUNCTION_UNKNOWN was allowed for optimize_trivial_count_query, and the result was wrong.

And two examples above just to show the difference, the behaviour hadn't been changed with this patch:

- SELECT * FROM test WHERE toDate(p) >= '2020-09-01' AND p <= '2020-09-01 00:00:00'
  In this case will be (FUNCTION_IN_RANGE, FUNCTION_IN_RANGE (due to non-strict), FUNCTION_AND)
  so it will prune everything out and nothing will be read.

- SELECT * FROM test WHERE toDate(p) >= '2020-09-01' AND toUnixTimestamp(p)%5==0
  In this case will be (FUNCTION_IN_RANGE, FUNCTION_UNKNOWN, FUNCTION_AND)
  and all, two, partitions will be scanned, but due to filtering later none of rows will be matched.
2020-11-25 23:09:17 +03:00
Azat Khuzhin
32f69dc76f Cleanup 01505_trivial_count_with_partition_predicate 2020-11-25 23:09:17 +03:00
Nikolai Kochetov
729272391f
Merge branch 'master' into ip-dict-no-trie 2020-11-25 23:07:19 +03:00
Nikolai Kochetov
99f1151236
Update arcadia_skip_list.txt 2020-11-25 23:06:37 +03:00
tavplubix
6477251ea1
Update BackgroundJobsExecutor.h 2020-11-25 23:06:00 +03:00
Azat Khuzhin
3f67e320dd Fix parsing of SETTINGS clause of the INSERT ... SELECT ... SETTINGS query
Before this patch the following query ignores the settings for INSERT:

   insert into test_parallel_insert select * from numbers_mt(65535*2) settings max_insert_threads=10

And the reason is that SETTINGS was parsed by the SELECT parser.
Fix this by push down the SETTINGS from the SELECT to INSERT.

Also note that since INSERT parser does not use ParserQueryWithOutput the
following works:

   insert into test_parallel_insert select * from numbers_mt(65535*2) format Null settings max_insert_threads=10
2020-11-25 22:53:58 +03:00
Azat Khuzhin
36dc23668d Fix formatting of SETTINGS clause of the INSERT query 2020-11-25 21:32:10 +03:00
Nikita Mikhaylov
f3f06dccac
Merge pull request #17121 from yshrotciv/patch-1
Update replication.md
2020-11-25 21:29:19 +03:00
Azat Khuzhin
688cb6b4d9 Update date_time_short perf test for toUnixTimestamp(Date()) 2020-11-25 21:17:11 +03:00
nikitamikhaylov
44f4064e9b update test 2020-11-25 20:51:07 +03:00
nikitamikhaylov
02a80230f8 remove comments 2020-11-25 20:51:07 +03:00
nikitamikhaylov
71d6126c6b better 2020-11-25 20:51:07 +03:00
nikitamikhaylov
4246971961 fix tests 2020-11-25 20:51:07 +03:00
nikitamikhaylov
d1eb9f02dd style 2020-11-25 20:51:06 +03:00
nikitamikhaylov
de9dc3a43f update copy pasted test 2020-11-25 20:51:06 +03:00
nikitamikhaylov
0779c7e0c3 better 2020-11-25 20:51:06 +03:00
nikitamikhaylov
b3087d0eb3 comments 2020-11-25 20:51:06 +03:00
nikitamikhaylov
f764332070 better merge 2020-11-25 20:51:06 +03:00
nikitamikhaylov
3f874af323 new interface for the function
(cherry picked from commit 89547e77cf)
2020-11-25 20:51:06 +03:00
nikitamikhaylov
85ac4c4f36 better
(cherry picked from commit 516b152af3)
2020-11-25 20:51:06 +03:00
Alexey Milovidov
fb234c2b17 Fix comments
(cherry picked from commit 7065e50c74)
(cherry picked from commit 1f21160041)
2020-11-25 20:51:06 +03:00
Alexey Milovidov
be84bd1aba Add missing file
(cherry picked from commit 2f3415be5d)
(cherry picked from commit a819558889)
2020-11-25 20:51:06 +03:00
Alexey Milovidov
a7739d9afb Make the code less bad
(cherry picked from commit 911cd77c1a)
(cherry picked from commit ac7267ce48)
2020-11-25 20:51:06 +03:00
nikitamikhaylov
88fec92921 initial
(cherry picked from commit 158665e84f)
2020-11-25 20:51:06 +03:00