Commit Graph

2127 Commits

Author SHA1 Message Date
Maksim Kita
7778172a1f Fixed compilable function 2021-05-08 17:39:35 +03:00
Maksim Kita
c79d7eae21 Refactored interfaces 2021-05-08 17:39:35 +03:00
Maksim Kita
24798ef07c Updated interfaces 2021-05-08 17:39:34 +03:00
Maksim Kita
d2eecfe593 Updated Nullable default implementation 2021-05-08 17:39:34 +03:00
Maksim Kita
6b70cbd53c Added jit example 2021-05-08 17:39:34 +03:00
Alexey Milovidov
e9c7aa5ab5 Remove some code 2021-05-08 17:12:26 +03:00
Alexey Milovidov
de1bc6d9f1 Add suppressions for PVS-Studio 2021-05-08 17:09:40 +03:00
Maksim Kita
108c2022d9 Function arrayDifference decimal math overflow 2021-05-08 17:01:30 +03:00
kssenii
c3eab60b8b Merge branch 'master' of github.com:ClickHouse/ClickHouse into poco-file-to-std-fs 2021-05-08 02:40:17 +03:00
Alexey Milovidov
bebdabc0ca Support Map with UUID keys 2021-05-07 20:42:16 +03:00
Alexey Milovidov
9c0dacd063 Fix error 2021-05-07 04:45:29 +03:00
Alexey Milovidov
a1855f3d5b Fix style 2021-05-07 04:43:02 +03:00
Alexey Milovidov
7d93734f54 gcd and lcm for big integers 2021-05-07 03:00:26 +03:00
Alexey Milovidov
fee0314057 Fix error 2021-05-07 02:17:39 +03:00
Alexey Milovidov
29f1a87016 Simplification 2021-05-06 19:16:31 +03:00
Alexey Milovidov
b461542388 If for UUID 2021-05-06 18:45:58 +03:00
Alexey Milovidov
9d4265d727 Fix mapAdd, mapSubstract; add support for big integers 2021-05-06 03:14:52 +03:00
Alexey Milovidov
35e72067b5 Fix hashes of UUID 2021-05-06 01:20:49 +03:00
kssenii
2dabdd0f73 Merge branch 'master' of github.com:ClickHouse/ClickHouse into poco-file-to-std-fs 2021-05-05 18:42:40 +03:00
Alexey Milovidov
199f928402 Shave off some lines of code 2021-05-05 15:01:19 +03:00
Alexey Milovidov
79beaae056 Shave off some lines of code 2021-05-05 15:01:01 +03:00
Alexey Milovidov
6473e956bb Implement TODO 2021-05-05 14:58:17 +03:00
Alexey Milovidov
a9a885bc43 Fix generateUUIDv4 2021-05-04 20:47:35 +03:00
Alexey Milovidov
962a7113f6 Remove code that I do not like (crazy templates) 2021-05-04 20:26:09 +03:00
万康
fa96613aeb update the way to get bitposition 2021-05-04 23:46:00 +08:00
Alexey Milovidov
1b01284acb Implement TODO 2021-05-04 18:41:58 +03:00
Alexey Milovidov
eea47a65d2 PVS-Studio 2021-05-04 15:13:47 +03:00
Alexey Milovidov
84fe2bfdf3 Return hashes of UUID 2021-05-04 14:53:29 +03:00
Alexey Milovidov
02ce9cc725 Untangle UUID 2021-05-04 01:46:51 +03:00
Alexey Milovidov
0677787d90 Fix abysmally low performance 2021-05-03 22:56:40 +03:00
Alexey Milovidov
b0bd9fd3b0 Add UInt128 where it is needed 2021-05-03 19:12:28 +03:00
Alexey Milovidov
8ecd9d36e6 Add UInt128 conversion functions 2021-05-03 18:41:37 +03:00
Alexey Milovidov
39bcf9d860 Fix style 2021-05-03 01:44:34 +03:00
Alexey Milovidov
9f74565948 PVS-Studio 2021-05-03 01:42:01 +03:00
Alexey Milovidov
f4100cf70c Remove harmful std::regex 2021-05-02 22:04:26 +03:00
Alexey Milovidov
30ef8ade6c Merge with master 2021-05-02 21:43:45 +03:00
Alexey Milovidov
1fda866881 Merge branch 'master' into normalize-bigint 2021-05-02 21:24:45 +03:00
万康
4bb63e1464 add function bitpositionToArray 2021-05-02 01:00:22 +08:00
kssenii
ee06936596 Merge branch 'master' of github.com:ClickHouse/ClickHouse into poco-file-to-std-fs 2021-05-01 17:24:31 +03:00
Maksim Kita
fa1e9de7f7
Merge pull request #23782 from ClickHouse/merging-array-product-function
Merging array product function
2021-05-01 00:53:57 +03:00
alexey-milovidov
eeae539a9f
Merge pull request #23799 from kitaisreal/function-default-implementation-for-nulls-small-optimization
Function default implementation for nulls small optimization
2021-04-30 21:50:24 +03:00
Maksim Kita
bcfcfe7fe9 Fixed style check 2021-04-30 17:16:51 +03:00
Maksim Kita
404b2d8fe8 Return constant branch 2021-04-30 17:14:01 +03:00
Maksim Kita
7467c5e3cf Function default implementation for nulls small optimization 2021-04-30 13:56:56 +03:00
Maksim Kita
44b966af5a Removed const path for arrayAggregation 2021-04-30 12:33:34 +03:00
Maksim Kita
318c4bb80d Add examples folder filter to ya.make.in 2021-04-30 11:25:52 +03:00
Maksim Kita
aa71b4a6df
Merge pull request #22242 from hexiaoting/dev_arrayproduct
Introduce arrayProduct function
2021-04-30 09:55:21 +03:00
kssenii
984d82c3f2 Update DiskLocal 2021-04-29 02:00:04 +03:00
kssenii
3386dc32d3 Change in Functions/* 2021-04-29 00:38:58 +03:00
dankondr
675d3e6c88 Fix code style 2021-04-28 20:09:46 +03:00
alexey-milovidov
fdc5a44202
Merge pull request #23644 from nikitamikhaylov/delete-unit-tests
Move non gtest unit tests to /examples folder
2021-04-28 07:28:18 +03:00
dankondr
780f58abc4 Fix code style 2021-04-27 19:54:05 +03:00
dankondr
1365a2c82e Fix include 2021-04-27 17:26:11 +03:00
Nikita Mikhaylov
9f55424250 move to examples everywhere 2021-04-27 01:51:42 +03:00
Alexey
283442e249 Merge branch 'master' of https://github.com/ClickHouse/ClickHouse into alexey-sm-DOCSUP-6702-document-timezoneOffset 2021-04-26 19:43:12 +00:00
Alexey
beca754aff Alias timeZoneOffset added to source code 2021-04-26 19:17:23 +00:00
Alexey Milovidov
f9d0b2fa6a Merge branch 'master' into normalize-bigint 2021-04-26 00:54:10 +03:00
Alexey Milovidov
649550c5ab Attempt to normalize big integers 2021-04-25 12:30:43 +03:00
Alexey Milovidov
8f01af62d9 Merge branch 'master' into normalize-bigint 2021-04-25 06:57:44 +03:00
Alexey Milovidov
263378bb20 Fix error in LIKE (found by SQLancer) 2021-04-25 03:58:44 +03:00
Alexey Milovidov
4ff812db7f Maybe better support for paths with whitespaces 2021-04-24 22:47:52 +03:00
Maksim Kita
ddcffcb723 Fixed tests 2021-04-22 00:19:01 +03:00
Maksim Kita
631d870ae3 Cast to array from empty array 2021-04-21 20:29:49 +03:00
Nikita Mikhaylov
d4e8f9676b
Merge pull request #21304 from amosbird/indexhint
Resurrect indexHint function.
2021-04-21 16:14:43 +03:00
Alexey Milovidov
416efbacbb Keep default timezone on DateTime operations if it was not provided explicitly #4854 2021-04-21 00:08:06 +03:00
Anton Popov
3d390b095a
regenerate ya.make 2021-04-20 18:58:53 +03:00
Anton Popov
8f57141fad
Merge pull request #23195 from CurtizJ/nested-update
Merging #22503
2021-04-20 14:57:47 +03:00
Amos Bird
32c84f77c3
Resurrect indexHint function. 2021-04-20 19:27:23 +08:00
Anton Popov
0a0c510aa2 minor fixes 2021-04-20 05:51:07 +03:00
hexiaoting
5dd8018c12 Merge remote-tracking branch 'origin/master' into dev-map-bug 2021-04-19 10:26:20 +08:00
Azat Khuzhin
2561a67fd8 Replace !__clang__ with !defined(__clang) to fix gcc builds
$ gg 'if !__clang__' | cut -d: -f1 | sort -u | xargs sed -i 's/#if !__clang__/#if !defined(__clang__)/g'
2021-04-18 23:37:50 +03:00
alexey-milovidov
83038f84af
Revert "Function arrayFold for folding over array with accumulator" 2021-04-18 03:34:05 +03:00
Alexey Milovidov
8ac953f459 Make function unhex case insensitive for compatibility 2021-04-17 19:31:35 +03:00
Alexey Milovidov
36fe378a17 Fix fairly terrible bug in LowCardinality #16171 2021-04-17 02:11:21 +03:00
dankondr
7e741338f2 Fix typo 2021-04-16 21:24:38 +03:00
dankondr
be97fd358e Fix problem with 3rd argument being const 2021-04-16 20:55:46 +03:00
dankondr
4c37eba92b Improve code readability 2021-04-16 20:46:46 +03:00
dankondr
58ed68c28e Fix writeNumber2 2021-04-16 20:44:56 +03:00
dankondr
a041cc9db0 Fix problem with offsets 2021-04-16 20:32:37 +03:00
dankondr
bce42dc973 Rewrite exception throws to fmt 2021-04-16 20:10:48 +03:00
dankondr
71137fd19b Override getArgumentsThatAreAlwaysConstant 2021-04-16 19:56:39 +03:00
Anton Popov
b14798af2a Merge branch 'dev_nested_upadte' of git://github.com/hexiaoting/ClickHouse into nested-update 2021-04-16 14:41:19 +03:00
Alexander Kuzmenkov
74b4c56ba4
Merge pull request #21589 from dmalkr/dmalkr/arrayFold
Function `arrayFold` for folding over array with accumulator
2021-04-16 14:23:53 +03:00
Alexander Kuzmenkov
440efb6fb6
Update arrayFold.cpp 2021-04-16 14:22:23 +03:00
alexey-milovidov
081bb6e275
Merge pull request #23000 from ClickHouse/speedup-intdiv
Dynamic dispatch for `intDiv`
2021-04-16 00:05:43 +03:00
dankondr
af48735e86 Fix argument check 2021-04-15 20:34:21 +03:00
dankondr
e6716779b2 Fix BAD_ARGUMENTS error code 2021-04-15 20:08:55 +03:00
Alexey Milovidov
bd49e696c4 Minor change 2021-04-15 16:59:00 +03:00
Dmitry Krylov
bf51f94f37 Fix constness 2021-04-15 21:46:15 +10:00
Alexey Milovidov
d19b2cb948 Fix build 2021-04-15 14:41:55 +03:00
Dmitry Krylov
75036debf4 Check type match of lambda and accumulator 2021-04-15 19:25:30 +10:00
Alexey Milovidov
2ae8839e3d Style 2021-04-15 01:28:40 +03:00
Alexey Milovidov
7f7e04117d Arcadia, ARM, PowerPC 2021-04-15 01:27:53 +03:00
Alexey Milovidov
f6f0d001cd Merge branch 'master' into speedup-intdiv 2021-04-15 01:27:15 +03:00
dankondr
0288cc5a1b Add dateName function 2021-04-14 23:29:17 +03:00
alexey-milovidov
496c2e45d0
Merge pull request #23036 from Enmk/fix_extractAllGroupsHorizontal_max_matches
Fixed erroneus failure of extractAllGroupsHorizontal on large columns
2021-04-14 15:57:19 +03:00
alexey-milovidov
d3f8a9c23a
Merge pull request #23044 from ClickHouse/array-has-any-all-generic
Fix unfinished code in GatherUtils #20272
2021-04-14 13:57:30 +03:00
alexey-milovidov
6a2a9cecdd
Update extractAllGroups.h 2021-04-14 01:24:46 +03:00
Vasily Nemkov
77bdb5b391 Fixed erroneus failure of extractAllGroupsHorizontal on large columns 2021-04-14 00:17:06 +03:00
Nikita Mikhaylov
cef9e19eb2 better 2021-04-13 22:39:41 +03:00
Nikita Mikhaylov
2549468c14 better 2021-04-13 22:39:41 +03:00
Alexey Milovidov
df44476307 Fix error 2021-04-13 22:32:02 +03:00
Alexey Milovidov
03662165f3 Comment 2021-04-13 22:03:52 +03:00
Alexey Milovidov
8bd5578c92 Less amount of template instantiations 2021-04-13 22:02:07 +03:00
Alexey Milovidov
42412f9a08 extern template 2021-04-13 21:59:55 +03:00
Alexey Milovidov
fb98915435 More safe CPU dispatching 2021-04-13 21:54:46 +03:00
Alexey Milovidov
b00c66cb36 More safe CPU dispatching 2021-04-13 21:53:55 +03:00
Alexey Milovidov
cdbc9d9fa0 Merge branch 'master' into speedup-intdiv 2021-04-13 20:43:54 +03:00
Alexey Milovidov
c01756014e More generic implementation of has 2021-04-13 20:08:49 +03:00
Alexey Milovidov
83a78a5aa7 Fix unfinished code in GatherUtils #20272 2021-04-13 16:56:39 +03:00
hexiaoting
4f36ac7f64 Fix error 2021-04-13 17:31:49 +08:00
hexiaoting
52bdec396b Merge remote-tracking branch 'origin/master' into dev_nested_upadte 2021-04-13 09:56:47 +08:00
hexiaoting
9e921023b8 Fix error 2021-04-13 09:53:39 +08:00
alexey-milovidov
ee9aaab4bc
Merge pull request #22937 from Enmk/formatDateTime_toDateTime64_fixes
Fixes: formatDateTime and toDateTime64
2021-04-13 01:40:25 +03:00
Alexey Milovidov
d5580a8e71 Dynamic dispatch for intDiv 2021-04-12 23:02:42 +03:00
Alexey Milovidov
ff0d3860d4 Fix typos + minor improvement #22314 2021-04-12 23:02:16 +03:00
Dmitry Krylov
df60724847 Fix constness 2021-04-12 20:29:58 +10:00
Dmitry Krylov
a3d57bd5af Check number of arguments 2021-04-12 20:29:35 +10:00
Dmitry Krylov
68bd27f3c5 Fix code style 2021-04-12 12:12:40 +10:00
Dmitry Krylov
35472bcc2f Update to new IFunction::create() 2021-04-12 11:37:44 +10:00
Dmitry Krylov
582f6d3a72 Remove unneeded branches of code 2021-04-12 10:23:31 +10:00
Dmitry Krylov
c2f326e2ae Remove unneeded branches of code 2021-04-12 10:23:31 +10:00
Dmitry Krylov
ce1b9b20d5 Remove unneeded branches of code 2021-04-12 10:23:31 +10:00
Dmitry Krylov
15ea9b3f22 Move arrayFold functionality to arrayFold.cpp 2021-04-12 10:23:31 +10:00
Dmitry Krylov
517ef8ebf4 Bug with string functions in arrayFold fixed 2021-04-12 10:23:31 +10:00
Dmitry Krylov
e3502dabc7 Remove debug messages 2021-04-12 10:23:31 +10:00
Dmitry Krylov
1861817bfc Remove debug messages 2021-04-12 10:23:31 +10:00
Dmitry Krylov
9446df026b Cleaning code 2021-04-12 10:23:31 +10:00
Dmitry Krylov
b19a06ba48 Fix to work with empty arrays 2021-04-12 10:23:31 +10:00
Dmitry Krylov
fbd43aeea8 Draft: taking into accout input arrays variable length 2021-04-12 10:23:31 +10:00
Dmitry Krylov
2e8a296cc9 Draft: very simple variant 2021-04-12 10:23:31 +10:00
Dmitry Krylov
7c47832405 Experiment: attempt to shrink arrays 2021-04-12 10:23:31 +10:00
Maksim Kita
b571656fd7
Merge pull request #22931 from Enmk/dateDiff_DateTime64_fix
Fixed dateDiff for DateTime64
2021-04-11 21:36:24 +03:00
Vasily Nemkov
ffd808f877
Removed redundant access specifier 2021-04-11 17:38:11 +03:00
Ivan
495c6e03aa
Replace all Context references with std::weak_ptr (#22297)
* Replace all Context references with std::weak_ptr

* Fix shared context captured by value

* Fix build

* Fix Context with named sessions

* Fix copy context

* Fix gcc build

* Merge with master and fix build

* Fix gcc-9 build
2021-04-11 02:33:54 +03:00
Anton Popov
329c9033a8 fix conversion from const map with nulls 2021-04-09 20:50:10 +03:00
Vasily Nemkov
4dcc1b2d2e Fixed formatDateTime for DateTime64 arguments 2021-04-09 19:39:54 +03:00
Vasily Nemkov
4a784bd2e3 Fixed dateDiff for DateTime64
Added tests that verify fix
- against DateTime64 vals of equal scale
- DateTime64 vs DateTime
- DateTime vs DateTime64
- DateTime64 vs Date
- Date vs DateTime64
2021-04-09 15:29:16 +03:00
alexey-milovidov
b8e239c211
Merge pull request #22821 from kitaisreal/functions-external-dictionaries-standardize-exception-throw
Functions ExternalDictionaries standardize exception throw
2021-04-08 10:41:41 +03:00
Maksim Kita
caff65f1c2 Functions ExternalDictionaries standardize exception throw 2021-04-07 20:52:12 +03:00
hexiaoting
ee24d9a5cc Merge remote-tracking branch 'origin/master' into dev_nested_upadte 2021-04-07 10:42:51 +08:00
hexiaoting
8c60f95551 Fix error 2021-04-07 10:39:01 +08:00
hexiaoting
7e0b43be28 Support decimal type overflow check 2021-04-07 10:34:00 +08:00
Azat Khuzhin
f157278b72 Safer SCOPE_EXIT
It executes the code in the dtor, that should never throw.
2021-04-06 21:10:37 +03:00
hexiaoting
38bd455be9 Rewrite arrayProduct implementation 2021-04-06 17:41:54 +08:00
Alexey Milovidov
54caa61af5 Fix comments 2021-04-04 12:33:06 +03:00
Alexey Milovidov
a0f2b85cd3 Make round function to behave consistently on non-x86_64 2021-04-04 05:21:56 +03:00
hexiaoting
6e8583a028 Add array size check for Nested Type subcolumns when Update 2021-04-02 19:31:33 +08:00
Maksim Kita
3b799c5d7d
Merge pull request #22413 from kitaisreal/added-function-dict-get-or-null
Added function dictGetOrNull
2021-04-02 11:39:01 +03:00
Maksim Kita
d06fb1197a
Merge pull request #22096 from kitaisreal/hierarchy-dictionaries-updated
Refactored hierarchy dictionaries interface
2021-04-02 11:38:01 +03:00
kssenii
b66e0401f6 Lowercase 2021-04-01 23:07:01 +03:00
Maksim Kita
2c522cf8bb
Update FunctionsExternalDictionaries.h 2021-04-01 15:06:08 +03:00
kssenii
799a1f177e Rename to SimpleJSON* 2021-04-01 14:24:10 +08:00
fastio
4daf011e0b add aliases to visitParam/visitParamExtract* functions 2021-04-01 14:24:10 +08:00
Alexey Milovidov
7589a014f9 Better fix 2021-04-01 03:44:02 +03:00
Alexey Milovidov
c9fac714b4 Merge branch 'master' into map-op-ubsan 2021-04-01 03:27:33 +03:00
Maksim Kita
f4ab8b84b6 Added comment 2021-03-31 22:56:30 +03:00
Maksim Kita
f2e6a0a97d Added function dictGetOrNull 2021-03-31 17:46:13 +03:00
Maksim Kita
55984e849c
Merge branch 'master' into hierarchy-dictionaries-updated 2021-03-31 15:55:07 +03:00
alexey-milovidov
124d9e14ad
Merge pull request #22387 from ClickHouse/fix-msan-range
Fix MSan report for function `range` with UInt256.
2021-03-31 09:05:10 +03:00
Alexey Milovidov
7f9c0e621a Merge branch 'virtualutil' of github.com:amosbird/ClickHouse into virtualutil 2021-03-31 08:19:39 +03:00
Alexey Milovidov
14c4cc2ccb Update ya.make 2021-03-31 08:19:15 +03:00
Alexey Milovidov
a59c66c266 Fix UBSan report in mapOp 2021-03-31 04:07:18 +03:00
Alexey Milovidov
c3b4587d9d Fix MSan report in function "range" 2021-03-31 03:54:40 +03:00
alexey-milovidov
5c15b8a896
Merge branch 'master' into virtualutil 2021-03-30 23:59:44 +03:00
Vladimir
5ae9f2c5bb
Merge pull request #21329 from depressed-pho/isIPAddressContainedIn 2021-03-30 13:26:49 +03:00
Alexey Milovidov
e9c2309c05 A comment 2021-03-30 02:02:53 +03:00
Alexey Milovidov
466c70fb7c Code simplification 2021-03-30 02:00:25 +03:00
Alexey Milovidov
230b2930b7 Merge branch 'master' into virtualutil 2021-03-30 00:43:00 +03:00
alexey-milovidov
bb925e16bf
Merge pull request #22042 from Slach/fix_issue_22028
case insensitive aliases for CONNECTION_ID() and VERSION()
2021-03-29 21:02:24 +03:00
Anton Popov
ea82e7725f
Merge pull request #21562 from CurtizJ/serialization-refactoring-4
Refactoring of data types serialization
2021-03-29 16:36:44 +03:00
vdimir
02a0caf28b
Fix build isIPAddressContainedIn 2021-03-29 16:28:51 +03:00
vdimir
ae4b8e3181
Rename isIPAddressContainedIn -> isIPAddressInRange 2021-03-29 12:56:11 +03:00
vdimir
81ff4f4791
Remove Nummable support from isIPAddressContainedIn, do not use OverloadResolver 2021-03-29 12:54:35 +03:00
vdimir
24aa25d7dc
Reuse some functions for IPAddressContainedIn 2021-03-29 12:04:05 +03:00
hexiaoting
8a7599c4b1 Introduce arrayProduct function 2021-03-29 10:35:08 +08:00
Slach
9761db7efb Merge branch 'master' of github.com:ClickHouse/ClickHouse into fix_issue_22028 2021-03-28 18:41:22 +01:00
Alexander Kuzmenkov
3dea1c8c01
Merge pull request #21946 from azat/tld-fixes
Fix cutToFirstSignificantSubdomainCustom()/firstSignificantSubdomainCustom() for 3+level domains
2021-03-26 21:19:09 +03:00
Maksim Kita
2cac8d13cc Updated tests and documentation 2021-03-26 18:42:32 +03:00
Maksim Kita
720e2e0501 Updated dictGetDescendants, dictGetChildren implementation 2021-03-26 18:42:32 +03:00
Maksim Kita
566541528d Update function naming 2021-03-26 18:42:32 +03:00
Maksim Kita
bbd180caf3 Added functions dictGetChildren, dictGetDescendants 2021-03-26 18:42:32 +03:00
Maksim Kita
9f2f0d1095 Refactored hierarchy dictionaries interface 2021-03-26 18:42:32 +03:00
PHO
26dc629366 Add a function isIPAddressContainedIn()
This function takes an IP address and a CIDR network prefix, and determines if the address is contained in the network. It supports both IPv4 and IPv6 addresses, and expects arguments to be strings.

ClickHouse doesn't support union types. We cannot use the native IPv4 and IPv6 types for this reason.
2021-03-26 12:11:35 +09:00
PHO
9ece398c35 Changed the return type of DB::getCIDRMaskIPv6()
It now returns std::array instead of uint8_t *. Also added DB::getCIDRMaskIPv4().
2021-03-26 12:11:34 +09:00
PHO
1868ca34b8 Fix build on GCC where std::isinf() cannot be called without the namespace prefix 2021-03-26 12:11:22 +09:00
alexey-milovidov
f4d014c022
Update connectionID.cpp 2021-03-26 02:38:49 +03:00
alexey-milovidov
0e42060523
Merge pull request #22114 from ucasFL/bar
Fix bar with invalid float value
2021-03-26 02:36:02 +03:00
Azat Khuzhin
b68517f69e Fix cutToFirstSignificantSubdomainCustom()/firstSignificantSubdomainCustom() for 3+level domains
Custom TLD lists (added in #17748), may contain domain of the 3-d level,
however builtin TLD lists does not have such records, so it is not
affected.

Note that this will significantly increase hashtable lookups.

Fixes: #17748
2021-03-26 00:00:16 +03:00
Azat Khuzhin
30cd1c6145 Fix typo in FirstSignificantSubdomainCustomLookup name 2021-03-26 00:00:16 +03:00
feng lv
55ba4ec15e Fix bar with invalid float value
fix
2021-03-25 13:28:07 +00:00
alexey-milovidov
52396acba1
Merge pull request #22064 from ClickHouse/fix-overflow-aes
Fix missing check in decrypt for AEAD mode
2021-03-25 16:01:44 +03:00
alexey-milovidov
cb6926629e
Merge pull request #22099 from ClickHouse/map-populate-series-ubsan
Fix UBSan report in mapPopulateSeries.
2021-03-25 16:00:21 +03:00
Anton Popov
6a15431be7 Merge remote-tracking branch 'upstream/master' into HEAD 2021-03-25 15:57:35 +03:00
Vitaly Baranov
86a293d6c8
Merge pull request #22057 from vitlibar/update-simdjson
Update simdjson
2021-03-25 13:27:05 +03:00
alexey-milovidov
94dabbac60
Merge pull request #22001 from ClickHouse/timezone-of
Add function `timezoneOf` and fix inconsistencies
2021-03-24 23:15:22 +03:00
Alexey Milovidov
c325ed65e2 Fix UBSan report in mapPopulateSeries 2021-03-24 23:10:15 +03:00
Slach
769162765c fix connectionID.cpp after fail https://clickhouse-test-reports.s3.yandex.net/22042/419e1555d66469aee90ffb991baad6b2b4f8b294/fast_test.html#fail1 2021-03-24 15:13:33 +05:00
Slach
7c580d8a01 Merge branch 'master' of github.com:ClickHouse/ClickHouse into fix_issue_22028 2021-03-24 09:35:05 +01:00
Alexey Milovidov
37948ac80a Fix style 2021-03-24 04:12:52 +03:00
Alexey Milovidov
a6c1b30b3c Merge branch 'master' into timezone-of 2021-03-24 04:12:05 +03:00
Alexey Milovidov
5dc9223288 Fix Arcadia 2021-03-24 04:11:57 +03:00
Alexey Milovidov
3e74f56261 Fix missing check in decrypt for AEAD mode 2021-03-24 03:34:30 +03:00
Alexey Milovidov
47b00ad11b Fix UBSan report in TransformDateTime64 2021-03-24 02:49:17 +03:00
Alexey Milovidov
4de5afed4e Whitespaces 2021-03-24 02:07:13 +03:00
alexey-milovidov
18c9167ba1
Merge pull request #22009 from ClickHouse/intdiv-ubsan-3
Fix UBSan report in intDiv #21769
2021-03-23 23:53:24 +03:00
alexey-milovidov
150a2df9df
Merge pull request #22026 from kitaisreal/cast-to-enum-nullable-fix
Cast to enum nullable fix
2021-03-23 23:51:19 +03:00
Vitaly Baranov
1f4df07e08 Update used version of simdjson to 0.9.1 2021-03-23 20:58:30 +03:00
alexey-milovidov
ed0ad9ec17
Update version.cpp 2021-03-23 20:30:50 +03:00
Slach
c977348076 fix build after fails https://clickhouse-test-reports.s3.yandex.net/22042/0bc0af117eb6faa554d77323f1026dc971abb470/fast_test/runlog.out.log 2021-03-23 21:06:09 +05:00
Slach
0bc0af117e fix build after fails https://clickhouse-test-reports.s3.yandex.net/22042/6ce139dd800fb658ab915adaba6bbd0ca075ce7a/fast_test.html#fail1 2021-03-23 20:20:44 +05:00
Slach
6ce139dd80 fix https://github.com/ClickHouse/ClickHouse/issues/22028 2021-03-23 19:31:05 +05:00
Anton Popov
2e1f293bd5
Merge pull request #21699 from CurtizJ/fix-map-field-conversion
Fix conversions for fields in function 'arrayElement' for type Map
2021-03-23 15:30:44 +03:00
Maksim Kita
75f5679bf0 Cast to enum nullable fix 2021-03-23 14:58:00 +03:00
Alexey Milovidov
c94841bca5 Fix UBSan report in intDiv #21769 2021-03-23 00:38:25 +03:00
Alexey Milovidov
84be58453b Add function timezoneOf and fix inconsistencies 2021-03-22 22:50:04 +03:00
Maksim Kita
849a980644 Updated ExternalDictionariesLoader interface with context parameter 2021-03-20 18:02:09 +03:00
Maksim Kita
32831e37ba Added table function dictionary 2021-03-19 15:47:27 +03:00
Maksim Kita
f340e71913
Merge pull request #21859 from kitaisreal/ddl-dictionary-current-database-name
DDL dictionary use current database name
2021-03-19 11:39:51 +03:00
Maksim Kita
a65bfaeab3 Fixed tests 2021-03-18 17:03:22 +03:00
Maksim Kita
0f95bcac0b DDL dictionary use current database name 2021-03-18 14:30:12 +03:00
Anton Popov
173d2ea1f4 Merge remote-tracking branch 'upstream/master' into HEAD 2021-03-16 02:50:14 +03:00
Anton Popov
ecd9220c77 minor fixes 2021-03-16 02:28:11 +03:00
Alexey Milovidov
3f67f4f47b Saturation for DateTime 2021-03-15 23:40:33 +03:00
Alexey Milovidov
eaeb4a3bf0 Merge branch 'master' into DateTime64_extended_range 2021-03-15 16:59:32 +03:00
Alexey Milovidov
b3d2948081 Fix UBSan report in modulo by constant 2021-03-14 17:31:07 +03:00
alexey-milovidov
53e21443eb
Merge branch 'master' into DateTime64_extended_range 2021-03-14 12:27:17 +03:00
Anton Popov
7304ef8255
remove debug output 2021-03-13 23:59:43 +03:00
Anton Popov
81ac6382a3 slightly better performance 2021-03-13 21:05:18 +03:00
Anton Popov
68b3cbbfe9 fix conversions for fields in function 'arrayElement' for type Map 2021-03-13 17:49:43 +03:00
Maksim Kita
854bfaf366 RangeHashed dictionary support has function 2021-03-13 14:57:56 +03:00
Anton Popov
ed42437219 Merge remote-tracking branch 'upstream/master' into HEAD 2021-03-13 01:41:26 +03:00
Nikita Mikhaylov
e234990cf6
Merge pull request #19257 from nikitamikhaylov/geometry_functions
Merging geometry functions
2021-03-12 17:05:24 +03:00
alexey-milovidov
494c6294b3
Merge pull request #21597 from qoega/fixes-clang-12-cmake-3.19
Prepare to use clang 12 and cmake 3.19
2021-03-11 23:45:53 +03:00
Nikita Mikhaylov
6928f2a409
Update pointInPolygon.cpp 2021-03-11 17:20:06 +03:00
Nikita Mikhaylov
b0577282eb
Update CMakeLists.txt 2021-03-11 17:19:03 +03:00
Nikita Mikhaylov
5ac5ae3b27
Merge pull request #21157 from CurtizJ/fix-type-map
Improve support of integer keys in data type Map
2021-03-11 15:49:57 +03:00
Nikita Mikhaylov
b219b7626e better 2021-03-11 15:19:15 +03:00
Nikita Mikhaylov
eecc12ff6a suppress warnings and skip tests in arcadia 2021-03-11 15:09:03 +03:00
Nikita Mikhaylov
0612d9ed09 Revert "mercator"
This reverts commit 27756c21d3691f270bcb36d0de271eed26f4c69a.
2021-03-11 15:08:20 +03:00
Nikita Mikhaylov
c81c742877 Revert "more mercator"
This reverts commit d4258922d1543211cf8b62f7c827a927712dca42.
2021-03-11 15:08:20 +03:00
Nikita Mikhaylov
7e6d1d43fe more mercator 2021-03-11 15:08:20 +03:00
Nikita Mikhailov
9f3e0874e5 mercator 2021-03-11 15:08:20 +03:00
Nikita Mikhailov
803c3e3d2c better 2021-03-11 15:08:19 +03:00
Nikita Mikhailov
a6c8d50cc2 review fix 2021-03-11 15:08:19 +03:00
Nikita Mikhailov
0e1b2d8fcf geographic -> spherical 2021-03-11 15:08:19 +03:00
Nikita Mikhailov
ac03ba31bf move to spherical point 2021-03-11 15:08:19 +03:00
Nikita Mikhailov
94b6cadb77 better 2021-03-11 15:08:19 +03:00
Nikita Mikhailov
44f0edacb2 another try 2021-03-11 15:08:19 +03:00
Nikita Mikhailov
c87d7de8b9 fix unit test 2021-03-11 15:08:19 +03:00
Nikita Mikhailov
ec7d930980 better 2021-03-11 15:08:19 +03:00
Nikita Mikhailov
053a95674d unit test 2021-03-11 15:08:19 +03:00
Nikita Mikhailov
a7427a9cdf better 2021-03-11 15:08:19 +03:00
Nikita Mikhailov
56700ed3e9 style 2021-03-11 15:08:19 +03:00
Nikita Mikhailov
681b0b63f1 return back all functions 2021-03-11 15:08:18 +03:00
Nikita Mikhailov
f6712479cd use parser type 2021-03-11 15:08:18 +03:00
Nikita Mikhailov
705c4dd60c callOnGeometryDataType instead of visitor 2021-03-11 15:08:18 +03:00
Nikita Mikhailov
5686c18291 changes after review 2021-03-11 15:08:18 +03:00
Nikita Mikhailov
954c206a53 rewrite parser 2021-03-11 15:08:18 +03:00
Nikita Mikhailov
fb454423b6 better 2021-03-11 15:08:18 +03:00
Nikita Mikhailov
557fa7c5c8 fix ubsan 2021-03-11 15:08:18 +03:00
Nikita Mikhailov
e78fc3109c better ubsan testing 2021-03-11 15:08:18 +03:00
Nikita Mikhailov
05cf1b5bc5 better 2021-03-11 15:08:18 +03:00
Nikita Mikhailov
2cce75808b fix build 2021-03-11 15:08:18 +03:00
Nikita Mikhailov
bf07c098a6 more checks of input type 2021-03-11 15:08:18 +03:00
Nikita Mikhailov
79b76d428f fix 2021-03-11 15:08:18 +03:00
Nikita Mikhailov
6a51ad425e add tests + improvements 2021-03-11 15:08:18 +03:00
Nikita Mikhailov
adfb2885c9 better 2021-03-11 15:08:18 +03:00
Nikita Mikhailov
a596227a02 tidy fix 2021-03-11 15:08:18 +03:00
Nikita Mikhailov
10d22e9db1 fix empty polygon 2021-03-11 15:08:17 +03:00
Nikita Mikhailov
be0ab21bb1 better 2021-03-11 15:08:17 +03:00
Nikita Mikhailov
41d006d493 try fix stress 2021-03-11 15:08:17 +03:00
Nikita Mikhailov
2475143ed3 fix style 2021-03-11 15:08:17 +03:00
Nikita Mikhailov
cdbdcbf793 update ya.make 2021-03-11 15:08:17 +03:00
Nikita Mikhailov
cfee417ce0 better 2021-03-11 15:08:17 +03:00
Nikita Mikhailov
3e36fae3df fix test 2021-03-11 15:08:17 +03:00
Nikita Mikhailov
0425d566d3 better 2021-03-11 15:08:17 +03:00
DoomzD
23616c773a fix polygonDistance 2021-03-11 15:08:17 +03:00
DoomzD
147c759ea4 fix polygonConvexHull 2021-03-11 15:08:17 +03:00
DoomzD
b26022d044 Add polygonPerimeter 2021-03-11 15:08:17 +03:00
DoomzD
153e35a33c Add polygonPerimeter, polygonsWithin and polygonsDistance 2021-03-11 15:08:17 +03:00
DoomzD
317cbdee2b Add polygonsEquals and polygonsSymDifference 2021-03-11 15:08:17 +03:00
DoomzD
c0c8e20c4d Add polygonArea and polygonConvexHull functions 2021-03-11 15:08:17 +03:00
Alexey Ilyukhov
05953f4cfa Add readWkt, svg 2021-03-11 15:08:17 +03:00
Alexey Ilyukhov
938ca6866d Fix less outstanding but still wrong code again 2021-03-11 15:08:17 +03:00
DoomzD
32f67a0fe5 Fix polygonsUnion first output polygon 2021-03-11 15:08:17 +03:00
DoomzD
bc1566b1f1 Add polygonsUnion function 2021-03-11 15:08:17 +03:00
DoomzD
aafceae019 Working version of polygonsIntersection 2021-03-11 15:08:17 +03:00
Alexey Ilyukhov
31f8e6330c Fix less outstanding but still wrong code 2021-03-11 15:08:16 +03:00
Alexey Ilyukhov
97a9110ad9 Fix outstandingly wrong code 2021-03-11 15:08:16 +03:00
DoomzD
50c59cc922 debug polygons intersection 2021-03-11 15:08:16 +03:00
DoomzD
249b94a7cd register function polygons intersection 2021-03-11 15:08:16 +03:00
DoomzD
13b841f6de Add polygons intersection function 2021-03-11 15:08:16 +03:00
Alexey Ilyukhov
d46998e114 Add remaining geo -> col 2021-03-11 15:08:16 +03:00
Alexey Ilyukhov
1259457695 Start adding geo -> col 2021-03-11 15:08:16 +03:00
Alexey Ilyukhov
e3290ecc78 help 2021-03-11 15:08:16 +03:00
Alexey Ilyukhov
afad9bf4d0 Trying to fix wkt 2021-03-11 15:08:16 +03:00
Alexey Ilyukhov
3be3d5cde8 Move all data types to header 2021-03-11 15:08:16 +03:00
Alexey Ilyukhov
fe83825211 Plz hekb 2021-03-11 15:08:16 +03:00
Alexey Ilyukhov
d0d6e6953c Fix build; add wkt 2021-03-11 15:08:16 +03:00
Alexey Ilyukhov
14a891057d Add other parsers 2021-03-11 15:08:16 +03:00
Alexey Ilyukhov
78e0db268c Add ring parser 2021-03-11 15:08:16 +03:00
Alexey Ilyukhov
33acc2aa5d fix 2021-03-11 15:08:16 +03:00
Alexey Ilyukhov
6d59be5ea4 Rewrite interface 2021-03-11 15:08:16 +03:00
Alexey Ilyukhov
9376b676e9 Add parseGeometry interface 2021-03-11 15:08:16 +03:00
Yatsishin Ilya
abbf4b01c2 Merge remote-tracking branch 'origin/master' into fixes-clang-12-cmake-3.19 2021-03-11 09:44:30 +03:00
Yatsishin Ilya
7b69ef92be gcc old cast check failed 2021-03-10 18:04:34 +03:00
Maksim Kita
45879472d3 DirectDictionary updated 2021-03-09 23:49:34 +03:00
Maksim Kita
43ba554191
Merge pull request #20595 from kitaisreal/cache-dictionaries-lru-cache
Cache dictionaries lru cache
2021-03-09 19:14:30 +03:00
Anton Popov
bc417cf54a refactoring of serializations 2021-03-09 17:46:52 +03:00
Yatsishin Ilya
71d745b4ec implicit const conversion 2021-03-09 17:31:54 +03:00
Amos Bird
b936619fa9
Rename 2021-03-09 22:00:04 +08:00
hexiaoting
0760759dc6 Add DataTypeMap support LowCardinality and FixedString type 2021-03-09 16:44:56 +08:00
Alexey Milovidov
355411dfa8 Merge branch 'master' into DateTime64_extended_range 2021-03-08 02:55:14 +03:00
Maksim Kita
492c3d0899
Merge pull request #21321 from kitaisreal/dictionary-source-executable-pool
Added ExecutablePool dictionary source
2021-03-08 01:36:33 +03:00
Maksim Kita
10c5518988 Fix tests 2021-03-06 14:38:27 +03:00
Maksim Kita
92b79420a4 Fixed ubsan test 2021-03-06 14:36:37 +03:00
Maksim Kita
e64b18fbac Added dictGet with multiple requested attributes 2021-03-06 14:36:37 +03:00
Maksim Kita
a22ec65e8a Fixed minor issues 2021-03-06 14:36:37 +03:00
Maksim Kita
dc0bb7485d Updated CacheDictionary 2021-03-06 14:36:37 +03:00
Alexey Milovidov
2b1ab0f927 Merge branch 'master' into DateTime64_extended_range 2021-03-06 02:25:43 +03:00
alexey-milovidov
35b304bdb1
Merge pull request #21393 from ClickHouse/dict-name-dot
Add a test for #15469
2021-03-06 01:47:17 +03:00
Maksim Kita
d3615aca67 Added tests 2021-03-05 13:17:46 +03:00
Alexey Milovidov
dce79d928f Merge branch 'dict-name-dot' of github.com:yandex/ClickHouse into dict-name-dot 2021-03-05 05:07:36 +03:00
Amos Bird
de94f33b05
Tiny fix 2021-03-05 00:21:52 +08:00
Maksim Kita
1eb1f3028c FunctionsExternalDictionaries safe case to ColumnTuple 2021-03-04 16:55:05 +03:00
Amos Bird
93b661ad5a
partition id pruning 2021-03-04 19:43:03 +08:00
Alexey Milovidov
7f1ae506fc The code is too complicated 2021-03-04 03:11:40 +03:00
Alexey Milovidov
4e8239e098 Merge branch 'master' into DateTime64_extended_range 2021-03-03 23:43:20 +03:00
alexey-milovidov
bd7b540b82
Merge pull request #21307 from amosbird/moduleopt
Specialize intDiv/module
2021-03-03 04:49:29 +03:00
Amos Bird
9411d496d9
Fix build 2021-03-02 23:17:02 +08:00
Amos Bird
134216dc4a Specialize intDiv/module 2021-03-02 16:27:28 +03:00
Amos Bird
ad4fd75fb4
mycli compatibility 2021-03-02 18:53:06 +08:00
Amos Bird
3df57da2d8
mysql client compatibility 2021-03-02 17:06:40 +08:00
Alexey Milovidov
ae9fea1d0a Fix gcc and clang-tidy 2021-02-28 04:05:04 +03:00
Alexey Milovidov
e5ae9cbb63 Fix Arcadia 2021-02-28 04:03:22 +03:00
Alexey Milovidov
4ab18cdcd8 Tests and documentation 2021-02-28 00:59:27 +03:00
Alexey Milovidov
2ac673b12a Update logic and tests 2021-02-27 22:33:55 +03:00
Alexey Milovidov
fd1cf49e92 Rewrite extractTextFromHTML function 2021-02-27 22:22:38 +03:00
Anton Popov
6ed3cf5511 Merge remote-tracking branch 'upstream/master' into HEAD 2021-02-26 15:10:52 +03:00
vdimir
9c1ba71416
Merge remote-tracking branch 'upstream/master' into fix-race-storage-join 2021-02-25 19:13:49 +03:00
vdimir
6f864ddb42
Minor changes in Hash/StorageJoin, add TableLockHolder to ExecutableFunctionJoinGet 2021-02-25 14:21:06 +03:00
vdimir
2f70e895fc
Update StorageJoin locking
Move joinGet into StorageJoin

Protect JoinSource with lock, add test

Add comments about locking logic
2021-02-25 12:31:22 +03:00
Anton Popov
ad5a03e8a4 improve support of integer keys in type Map 2021-02-24 21:13:26 +03:00
Anton Popov
b6a519cd04 Merge remote-tracking branch 'upstream/master' into HEAD 2021-02-24 19:45:38 +03:00
Vasily Nemkov
2d03d330bc Extended range of DateTime64 to years 1925 - 2238
The Year 1925 is a starting point because most of the timezones
switched to saner (mostly 15-minutes based) offsets somewhere
during 1924 or before. And that significantly simplifies implementation.

2238 is to simplify arithmetics for sanitizing LUT index access;
there are less than 0x1ffff days from 1925.

* Extended DateLUTImpl internal LUT to 0x1ffff items, some of which
  represent negative (pre-1970) time values.
  As a collateral benefit, Date now correctly supports dates up to 2149
  (instead of 2106).
* Added a new strong typedef ExtendedDayNum, which represents dates
  pre-1970 and post 2149.
* Functions that used to return DayNum now return ExtendedDayNum.
* Refactored DateLUTImpl to untie DayNum from the dual role of being
  a value and an index (due to negative time). Index is now a different
  type LUTIndex with explicit conversion functions from DatNum, time_t,
  and ExtendedDayNum.
* Updated DateLUTImpl to properly support values close to epoch start
  (1970-01-01 00:00), including negative ones.
* Reduced resolution of DateLUTImpl::Values::time_at_offset_change
  to multiple of 15-minutes to allow storing 64-bits of time_t in
  DateLUTImpl::Value while keeping same size.
* Minor performance updates to DateLUTImpl when building month LUT
  by skipping non-start-of-month days.
* Fixed extractTimeZoneFromFunctionArguments to work correctly
  with DateTime64.
* New unit-tests and stateless integration tests for both DateTime
  and DateTime64.
2021-02-24 17:08:35 +02:00
alexey-milovidov
29a29f5060
Merge pull request #19765 from kssenii/fffix
Fix #19371
2021-02-24 17:40:15 +03:00
Maksim Kita
395526cb80
Merge pull request #21120 from hexiaoting/dev-map-bug
Bug fix: Tuple cast to Map
2021-02-24 17:21:00 +03:00
Amos Bird
acfbae7107
Fix replace,All functions so that they don't generate garbage to stderr 2021-02-23 22:39:05 +08:00
hexiaoting
e123c6ef9d Bug fix: Tuple cast to Map 2021-02-23 18:42:33 +08:00