Commit Graph

1251 Commits

Author SHA1 Message Date
pyos
7483ed24f0 Implement jit for logic functions 2018-05-01 14:43:15 +03:00
Tsarkova Anastasia
210a389592 Getting rid of measure action, other small fixes applied. 2018-04-30 21:33:32 +02:00
pyos
e4ace21f24 Remove laziness on nullable arguments from default implementation
It breaks semantics, sadly.
2018-04-30 15:35:32 +03:00
pyos
4970b06b57 Remove outdated comments 2018-04-30 02:21:45 +03:00
pyos
039c377a7a Work around a bug in llvm::IRBuilder::CreateMaxNum 2018-04-30 02:07:39 +03:00
pyos
059bbcacca Implement jit for most arithmetic functions, remove the test function 2018-04-30 01:43:02 +03:00
Tsarkova Anastasia
a99ff6f380 Fix tests. 2018-04-29 23:48:33 +02:00
pyos
b4c7bee12b Merge branch 'master' of https://github.com/yandex/ClickHouse into llvm-jit 2018-04-29 23:22:18 +03:00
pyos
1be009d485 Remove getDefaultNativeValue in favor of llvm::Constant::getNullValue 2018-04-29 20:32:30 +03:00
Tsarkova Anastasia
4bce6035b1
Merge branch 'master' into master 2018-04-29 18:02:34 +02:00
Tsarkova Anastasia
2c96b1c684 Add comments. Change projection restoring function. 2018-04-29 15:49:58 +02:00
pyos
01aaf99d75 Use C++17 fold expressions to simplify FunctionsArithmetic.h 2018-04-29 16:04:28 +03:00
pyos
fb577b1049 Hide the whole JIT API behind #if USE_EMBEDDED_COMPILER
Kind ugly, but at least the conditionals are used consistently now.
2018-04-29 13:48:16 +03:00
pyos
6e05c5ace4 compilePrologue() isn't particularly useful after all.
Basically the only thing it can do that compile() can't is create 'alloca'
instructions, which are only needed to get pointers to stack variables.
Given that dynamically-sized allocations aren't possible with this API,
such pointers are probably completely pointless (heh).
2018-04-28 18:11:23 +03:00
pyos
a1eb938ed2 Inline nullable number constants into compiled code.
Also, protect against some segfaults during compilation by checking
correctness of the type returned by compile().
2018-04-28 17:12:00 +03:00
pyos
ccc895d162 Represent nullable types as pairs instead of pointers.
Turns out LLVM has insertvalue & extractvalue for struct in registers. This is
faster than pointers because null checks are now subject to more optimizations.
2018-04-28 14:12:23 +03:00
pyos
979c4d959f Let jit-compilable functions deal with NULLs themselves.
And provide a default implementation of compile() for nullable columns
that actually works and is consistent with execute().
2018-04-28 00:34:27 +03:00
pyos
c95f8a669f Throw in untyped versions of IFunction::{isCompilable,compile}
IFunction inherits IFunctionBase for some reason despite not actually knowing
the types, so these two methods make no sense. The versions with DataTypes&
as an argument should be used instead.
2018-04-25 20:07:19 +03:00
pyos
0da110234c Do not compile the jit if USE_EMBEDDED_COMPILER is disabled 2018-04-25 16:01:00 +03:00
pyos
df2d2e0b25 Tweak the jit compilation API to be more amenable to lazy computation 2018-04-25 13:37:26 +03:00
pyos
3810173103 Remove IFunction::createResultColumn.
Given that the list of supported types is hardcoded in
LLVMContext::Data::toNativeType, this method is redundant because
LLVMPreparedFunction can create a ColumnVector itself.
2018-04-25 13:37:26 +03:00
pyos
8c8a8f9c0f Extend the test jit-compilable function to arbitrary numbers 2018-04-25 13:37:25 +03:00
pyos
407008a4d9 Separate jit-compilability checks from actual compilation 2018-04-25 13:37:25 +03:00
pyos
e96a5e8344 Implement JIT compilation, without a loop for now.
It actually seems to work, so long as you only have one row that is. E.g.

    > select something(cast(number + 6 as Float64), cast(number + 2 as Float64)) from system.numbers limit 1';
    8

with this IR:

    define void @"something(CAST(plus(number, 6), 'Float64'), CAST(plus(number, 2), 'Float64'))"(void**, i8*, double*) {
    entry:
      %3 = load void*, void** %0
      %4 = bitcast void* %3 to double*
      %5 = load double, double* %4
      %6 = getelementptr void*, void** %0, i32 1
      %7 = load void*, void** %6
      %8 = bitcast void* %7 to double*
      %9 = load double, double* %8
      %10 = fadd double %5, %9
      store double %10, double* %2
      ret void
    }
2018-04-25 13:37:25 +03:00
pyos
851684de51 Add a JIT interface for row-wise default-nullable functions.
Not actually implemented, though. It does print out some jit-compiled stuff,
but that's about it. For example, this query:

    select number from system.numbers where something(cast(number as Float64)) == 4

results in this on server's stderr:

    define double @"something(CAST(number, 'Float64'))"(void**, i8*, void*) {
    "something(CAST(number, 'Float64'))":
      ret double 1.234500e+04
    }

(and an exception, because that's what the non-jitted method does.)

As one may notice, this function neither reads the input (first argument;
tuple of arrays) nor writes the output (third argument; array), instead
returning some general nonsense.

In addition, `#if USE_EMBEDDED_COMPILER` doesn't work for some reason,
including LLVM headers requires -Wno-unused-parameter, this probably only
works on LLVM 5.0 due to rampant API instability, and I'm definitely
no expert on CMake. In short, there's still a long way to go.
2018-04-25 13:37:25 +03:00
pyos
27d90fb941 Add an example function that uses LLVM to compile its own body 2018-04-25 13:37:25 +03:00
alexey-milovidov
6c73fb86e3 Update FunctionsMath.h 2018-04-24 10:11:03 -07:00
Babacar Diassé
22b2099b0b use exp10 and cbrt from vectorclass when enabled 2018-04-24 10:11:03 -07:00
Tsarkova Anastasia
12c8014e5c Conditional computations. 2018-04-24 09:16:39 +02:00
Nikolai Kochetov
792caf4294 added IColumn::select 2018-04-23 21:20:52 +03:00
Nikolai Kochetov
46d47cd892 added IColumn::select 2018-04-23 21:19:34 +03:00
Nikolai Kochetov
4369613435 added IColumn::select 2018-04-23 19:40:25 +03:00
Alexey Milovidov
d71b3a95ef Renamed PK to Key where it's appropriate #2246 2018-04-20 03:20:50 +03:00
Alexey Milovidov
ef14902ef9 Style #1925 2018-04-19 07:25:08 +03:00
alexey-milovidov
0612977bc3
Merge pull request #1925 from zhang2014/fix/ISSUES-995
ISSUES-995 support relative path with domain
2018-04-19 07:19:23 +03:00
Nikolai Kochetov
e9bc071837 default implementation for functions with ColumnWithDictionary arguments 2018-04-17 20:47:27 +03:00
Nikolai Kochetov
c6a3fec726 Merge branch 'master' into data-type-with-dictionary 2018-04-17 13:44:19 +03:00
Nikolai Kochetov
0f0d5b3c0c added DataTypeWithDictionary [#CLICKHOUSE-3621] 2018-04-17 13:43:46 +03:00
proller
c26b3bdef1
Fix split shared build; fix build without system odbc libs (#2191)
* Fix split shared build

* Fix build without system odbc libs

* Move dbms/src/Common/iostream_debug_helpers.h -> libs/libcommon/include/common/iostream_debug_helpers.h

* Fix build with libiodbc
2018-04-09 06:52:39 -07:00
Alexey Milovidov
3f264f07e9 Removed excessive library dependencies #2180 2018-04-07 05:29:12 +03:00
Alexey Milovidov
ac58f92a97 Fixed error with IN where left hand side is nullable #1846 2018-04-06 08:12:47 +03:00
Alexey Milovidov
6452a3bb76 Removed (obsolete) special handling for Arrays in the left hand side of IN [#CLICKHOUSE-2] 2018-04-05 23:52:01 +03:00
谢磊
c898986650
change the return type of funciton countEqual
the maximum length of the array is defined as UInt64.
the maximum of `UInt32` just 4294967295.
it's better to define the return type of the function `countEqual` as `UInt64`.
2018-03-31 12:54:06 -05:00
Alexey Milovidov
b997830289 Fixed error found by Artemeey Gavryushin [#CLICKHOUSE-3] 2018-03-29 18:31:59 +03:00
Nikolai Kochetov
bd3f2ea361 Merge branch 'stricter-mutable-column-semantic-3' into stricter-mutable-column-semantic-2 2018-03-20 22:47:40 +03:00
Nikolai Kochetov
476d4b339c Immutable construction for columns 2018-03-20 22:45:10 +03:00
Nikolai Kochetov
1f4db58d53 fix test 2018-03-20 20:01:13 +03:00
Nikolai Kochetov
a399c17f01 && - qualified IColumn::mutate 2018-03-20 17:01:00 +03:00
Alexey Milovidov
90aa6374a7 Revert "Preparation #2026"
This reverts commit 60ecc03253.
2018-03-17 21:29:50 +03:00
Alexey Milovidov
60ecc03253 Preparation #2026 2018-03-17 20:46:25 +03:00
Alexey Milovidov
536a4a0c52 More checks [#CLICKHOUSE-2] 2018-03-16 07:49:22 +03:00
Alexey Milovidov
30192b1b42 Fixed backward compatibility [#CLICKHOUSE-3650]. 2018-03-16 06:13:13 +03:00
Alexey Milovidov
e272f6d79e Not a fix [#CLICKHOUSE-3650]. 2018-03-16 06:03:17 +03:00
Alexey Milovidov
a16dd1cee7 Little better [#CLICKHOUSE-3650] 2018-03-16 04:22:02 +03:00
Alexey Zatelepin
5906c9a988 rename for clarity 2018-03-13 18:00:28 +03:00
Alexey Milovidov
7577b1db14 Added function "throwIf" [#CLICKHOUSE-2543] 2018-03-10 03:18:57 +03:00
Nikolai Kochetov
871a560b37 merged with master 2018-03-05 15:36:17 +03:00
Alexey Milovidov
63467dbcc2 Fixed error #1947 2018-02-28 22:36:01 +03:00
alexey-milovidov
924cc3451f
Merge pull request #1955 from yandex/CLICKHOUSE-3606
Added consistent hashing functions
2018-02-27 10:52:41 +03:00
Vitaliy Lyudvichenko
cf5c378ed7 Add optimized version of sumbur hash, reduced buckets range. [#CLICKHOUSE-3606] 2018-02-27 03:01:51 +03:00
Alexey Zatelepin
2a56dd075f fix typo 2018-02-26 22:33:16 +03:00
Alexey Zatelepin
1564e31616 check that lengths of arrays passed to arrayReduce() are equal [#CLICKHOUSE-3250] #1142 2018-02-26 19:58:51 +03:00
Vitaliy Lyudvichenko
120530e44c Add requested changes. [#CLICKHOUSE-3606] 2018-02-26 15:14:20 +03:00
Vitaliy Lyudvichenko
077f413a0d Added consistent hashing functions. [#CLICKHOUSE-3606] 2018-02-24 00:22:52 +03:00
Alexey Milovidov
c44108d5eb Allow to CAST Nullable type to non-Nullable as long as there are no NULL values #1947 2018-02-23 00:20:02 +03:00
zhang2014
e1c31494f2 ISSUES-995 resolve some opinions 2018-02-22 13:39:49 +08:00
Alexey Zatelepin
610f70fbeb forbid non-deterministic functions in primary and partition keys [#CLICKHOUSE-3455] 2018-02-21 20:54:16 +03:00
zhang2014
219de205e3 ISSUES-995 fix cut www 2018-02-20 09:34:50 +08:00
zhang2014
bd10613c47 ISSUES-995 support relative path 2018-02-19 19:49:49 +08:00
Alexey Milovidov
95d2d68c7d Header in every stream: development [#CLICKHOUSE-2] 2018-02-18 05:22:32 +03:00
Alexey Milovidov
9e1638e1dd Header in every stream: development [#CLICKHOUSE-2] 2018-02-17 20:09:18 +03:00
Alexey Milovidov
d02874bf54 Header in every stream: development [#CLICKHOUSE-2] 2018-02-17 06:06:01 +03:00
Alexey Milovidov
3204b9688c Header in every stream: development [#CLICKHOUSE-2] 2018-02-17 05:35:09 +03:00
Alexey Milovidov
6f96857427 Header in every stream: development [#CLICKHOUSE-2] 2018-02-17 05:27:34 +03:00
Alexey Milovidov
c320b360c6 Merge branch 'master' of github.com:yandex/ClickHouse into header-in-input-streams 2018-02-16 21:23:29 +03:00
Alexey Zatelepin
87b72b8e39 rename musl_exp10 -> preciseExp10 for coding style compatibility 2018-02-16 17:51:14 +03:00
Alexey Zatelepin
8fdb68ef79 add musl_ prefix to exp10 functions to avoid confusion with symbols from the system libm 2018-02-16 17:01:50 +03:00
Alexey Milovidov
4b2cff20ea Whitespace [#CLICKHOUSE-2] 2018-02-15 19:10:25 +03:00
javi
e08199c81a removed extra line break 2018-02-15 16:53:55 +03:00
javi
e69421e7a6 fixed function and added test and doc 2018-02-15 16:53:55 +03:00
javi santana
c810db2a01 tests wip 2018-02-15 16:53:55 +03:00
javi santana
0297a598b9 function working 2018-02-15 16:53:55 +03:00
javi
95211cde25 added basic cumsum impl 2018-02-15 16:53:55 +03:00
Alexey Milovidov
3656aa0606 Improved performance of function arrayElement with constant array when one of element is an empty array #1889 2018-02-13 00:06:13 +03:00
Alexey Milovidov
55c969d073 Added test [#CLICKHOUSE-2] 2018-02-12 03:55:46 +03:00
Alexey Milovidov
95bc1ffd2e Added functions parseDateTimeBestEffort, parseDateTimeBestEffortOrZero, parseDateTimeBestEffortOrNull [#CLICKHOUSE-2] 2018-02-12 02:57:07 +03:00
Alexey Milovidov
c704f8b10c Fixed build #1879 2018-02-09 22:32:12 +03:00
alexey-milovidov
8fb9967903
Merge pull request #1879 from yandex/lambdas-without-prerequisites
Lambdas without prerequisites
2018-02-09 22:22:58 +03:00
alexey-milovidov
c5dd6a9fed
Update IFunction.h 2018-02-09 22:20:18 +03:00
alexey-milovidov
1c308d7d6b
Update IFunction.h 2018-02-09 22:15:40 +03:00
alexey-milovidov
1b2b31b24e
Update FunctionsMiscellaneous.h 2018-02-09 22:06:29 +03:00
alexey-milovidov
fb58050994
Update FunctionsMiscellaneous.h 2018-02-09 22:02:01 +03:00
Alexey Milovidov
0bc7772bbf Miscellaneous #1881 #180 2018-02-09 21:10:32 +03:00
Alexey Milovidov
a101b735a6 Miscellaneous #1881 #180 2018-02-09 21:06:31 +03:00
zhang2014
7f4f723aa0 ISSUES-180 fix empty function with FixedString 2018-02-10 00:37:13 +08:00
zhang2014
7a1e5a0971 ISSUES-180 fix empty function with FixedString 2018-02-09 19:05:19 +08:00
Nikolai Kochetov
bad2b8c032 fix build [#CLICKHOUSE-3550] 2018-02-08 20:20:12 +03:00
Nikolai Kochetov
733450d1dd added more comments [#CLICKHOUSE-3550] 2018-02-08 20:20:10 +03:00
Nikolai Kochetov
64b0279af5 removed ColumnExpression and DataTypeExpression [#CLICKHOUSE-3550] 2018-02-08 20:20:10 +03:00
Nikolai Kochetov
27179b375a removed prerequisites [#CLICKHOUSE-3550] 2018-02-08 20:18:52 +03:00
Nikolai Kochetov
583ff32fe8 changed IFunction 2018-02-08 20:18:15 +03:00
Nikolai Kochetov
b0f66bb234 remote don't use rpc for local replicas 2018-01-29 13:08:20 +03:00
alexey-milovidov
bea49ca136
Merge pull request #1741 from yandex/array-functions-hasAll-hasAny-intersect
Array functions hasAll hasAny arrayIntersect arrayResize
2018-01-26 12:06:48 +03:00
Vitaliy Lyudvichenko
b4ab7d4b8e Make early deduplication with block number creation. [#CLICKHOUSE-3545] 2018-01-23 18:50:29 +03:00
Nikolai Kochetov
ff0328aee7 fix build [#CLICKHOUSE-2998] 2018-01-22 13:18:55 +03:00
Alexey Milovidov
61e5b0476f Removed experimental implementations of pointInPolygon variants [#CLICKHOUSE-2] 2018-01-19 23:22:47 +03:00
Nikolai Kochetov
677758edaa added function arrayResize [#CLICKHOUSE-2998]
added test for arrayResize [#CLICKHOUSE-2998]
2018-01-19 22:32:06 +03:00
Nikolai Kochetov
4fb9ad3981 added push to GatherUtils [#CLICKHOUSE-2998] 2018-01-19 22:32:01 +03:00
proller
9ea2521944 Fix macos build 2018-01-19 20:04:32 +03:00
Nikolai Kochetov
ea7ccda006 added ValueSourceVisitor, simplified concat for multiple arguments [#CLICKHOUSE-2998] 2018-01-19 16:48:18 +03:00
Alexey Milovidov
f2a65f222a Fixed bad code in implementation of NULLs [#CLICKHOUSE-2] 2018-01-19 05:15:10 +03:00
Alexey Milovidov
3e3d7b354a Updated re2 to the latest version [#CLICKHOUSE-2] 2018-01-19 04:18:47 +03:00
Nikolai Kochetov
de274b317a added ArraySourceVisitor and ArraySinkVisitor [#CLICKHOUSE-2998] 2018-01-18 18:50:35 +03:00
Nikolai Kochetov
694b305036 added arrayIntersect [#CLICKHOUSE-3504] 2018-01-17 14:36:02 +03:00
proller
d97b2edc7c Make separate libs Common/ZooKeeper and Common/ConfigProcessor (#1749)
* Make separate libs Common/ZooKeeper and Common/ConfigProcessor
renamed:    dbms/src/Common/StringUtils.h -> dbms/src/Common/StringUtils/StringUtils.h

* Fix space

* Fix data in system.build_options

* merge

* merge
2018-01-15 22:07:47 +03:00
Alexey Milovidov
ce5de79263 Fixed tests #1665 2018-01-14 03:12:23 +03:00
Alexey Milovidov
610b64679f Extended domain of function reinterpretAsString #1665 2018-01-14 01:26:49 +03:00
Nikolai Kochetov
515cb7fbca renamed getLeastCommonType => getLeastSupertype; getMostCommonType => getMostSubtype [#CLICKHOUSE-3504] 2018-01-11 21:47:02 +03:00
Nikolai Kochetov
0d3ba65e0e fixed cast for arrays [#CLICKHOUSE-3504] 2018-01-10 22:52:39 +03:00
Nikolai Kochetov
8ceb85bcca moved GatherUtils* to GatherUtils/ [#CLICKHOUSE-3504] 2018-01-10 21:59:48 +03:00
Nikolai Kochetov
a76bb9660c added functions arrayAny and arrayAll [#CLICKHOUSE-3504] 2018-01-10 21:59:14 +03:00
Alexey Milovidov
0bfea2f52c Miscellaneous [#CLICKHOUSe-2] 2018-01-10 03:04:08 +03:00
Alexey Milovidov
005f6b96fa Added function "sleepEachRow" for testing purposes #1713 2017-12-30 07:50:12 +03:00
Alexey Milovidov
b96ae0aa0e Added function "sleepEachRow" for testing purposes #1713 2017-12-30 07:29:51 +03:00
Alexey Milovidov
28c6804c10 Miscellaneous [#CLICKHOUSE-2]. 2017-12-28 07:50:14 +03:00
Alexey Milovidov
fcdd5de47d Revert "Removed questionable code (2) [#CLICKHOUSE-2]."
This reverts commit fcabe8b888.
2017-12-28 07:39:19 +03:00
Alexey Milovidov
798299ba89 Merge branch 'aavdonkin-master' 2017-12-28 07:33:55 +03:00
Alexey Milovidov
104b09604a Merging [#CLICKHOUSE-3114] 2017-12-28 00:45:05 +03:00
Alexey Milovidov
c89041ce63 Removed questionable code (2) [#CLICKHOUSE-2]. 2017-12-26 01:51:04 +03:00
Alexey Milovidov
ec71908b00 Revert "Removed questionable code (2) [#CLICKHOUSE-2]."
This reverts commit fcabe8b888.
2017-12-26 00:57:29 +03:00
Alexey Milovidov
fcabe8b888 Removed questionable code (2) [#CLICKHOUSE-2]. 2017-12-26 00:32:33 +03:00
Alexey Milovidov
a85b2e5a95 Removed questionable code [#CLICKHOUSE-2]. 2017-12-26 00:10:46 +03:00
Alexey Milovidov
73ae622b12 Moved functions to work with tuples to separate file [#CLICKHOUSE-2]. 2017-12-25 22:10:25 +03:00
Alexey Milovidov
454de9243e Fixed build [#CLICKHOUSE-2] 2017-12-25 10:18:27 +03:00
Alexey Milovidov
04eb0b896c Added proper support for Nullable arguments for function OR #1416 2017-12-25 09:33:51 +03:00
Alexey Milovidov
9b914cf93e Simplification #1416 2017-12-25 08:48:53 +03:00
Alexey Milovidov
d899d3f8f5 Added functions toNumberOrNull from String argument #1322 2017-12-25 08:22:33 +03:00
Alexey Milovidov
de8e504e02 Miscellaneous [#CLICKHOUSE-2]. 2017-12-25 07:10:43 +03:00
Alexey Milovidov
f7838e7e39 Miscellaneous [#CLICKHOUSE-2]. 2017-12-25 07:09:48 +03:00
Alexey Milovidov
8ff93487e3 Miscellaneous [#CLICKHOUSE-2]. 2017-12-25 07:01:46 +03:00
Alexey Milovidov
a168c77ee4 Proper conversions from String to Nullable types if the value cannot be parsed: development #1322 2017-12-25 05:57:54 +03:00
Alexey Milovidov
82d429f7ed Allow for function "tupleElement" to get an edge of Array of Tuple (preparation for natural support of Nested) [#CLICKHOUSE-2]. 2017-12-24 12:56:30 +03:00
Alexey Milovidov
0f51be4191 Added support for named tuples in function tupleElement [#CLICKHOUSE-2]. 2017-12-24 12:34:40 +03:00
proller
371d3907b5 Fix dictionary FunctionDictGetOrDefault 2017-12-24 02:16:40 +03:00
Alexey Milovidov
a1fe019b5c Fixed possibility of infinite recursion in IFunction::defaultImplementationForConstantArguments when wrong number of arguments is passed to a function [#CLICKHOUSE-2]. 2017-12-23 04:54:51 +03:00
Alexey Milovidov
75f9ff1717 Fixed error found by M.Filimonov [#CLICKHOUSE-2]. 2017-12-23 04:35:25 +03:00
Alexey Milovidov
eebdac1f0e Fixed build #1676 2017-12-22 22:26:56 +03:00
Kirill Shvakov
af400da8eb add toStartOfFifteenMinutes function 2017-12-22 13:04:24 +02:00
Alexey Milovidov
7a15be8e63 Fixed behaviour of "visitParamExtract" functions according to the documentation [#CLICKHOUSE-2]. 2017-12-22 05:25:03 +03:00
Alexey Milovidov
0972d7586a Added support for toQuarter, toRelativeQuarterNum functions. Enabled toRelativeHour/Minute/Second for Date arguments. Made function 'now' case insensitive. Added function 'dateDiff' that is needed for ODBC driver [#CLICKHOUSE-2]. 2017-12-22 04:54:29 +03:00
Alexey Milovidov
74f191dfd3 Introduced intExp functions; using it where appropriate; make them available in SQL [#CLICKHOUSE-3]. 2017-12-22 02:46:34 +03:00
Alexey Milovidov
584a263d79 Simplification of aggregate functions: development [#CLICKHOUSE-2]. 2017-12-21 05:08:25 +03:00
Alexey Milovidov
c990740b33 Simplification of aggregate functions: development [#CLICKHOUSE-2]. 2017-12-21 05:08:25 +03:00
Alexey Milovidov
c8d8016bbb Fixed bad code [#CLICKHOUSE-2]. 2017-12-19 22:56:48 +03:00
Alexey Milovidov
80e48cc899 Better semantic of sharing columns: development [#CLICKHOUSE-2]. 2017-12-19 04:42:24 +03:00
Alexey Milovidov
4e8a70a29f Better semantic of sharing columns: development [#CLICKHOUSE-2]. 2017-12-19 04:13:20 +03:00
Alexey Milovidov
02821f4861 Fixed error [#CLICKHOUSE-2]. 2017-12-19 03:26:16 +03:00
Alexey Milovidov
93a300bea4 Miscellaneous [#CLICKHOUSE-2]. 2017-12-19 00:49:34 +03:00
Alexey Milovidov
339e22d014 Fixed error found by M.Filimonov [#CLICKHOUSE-2]. 2017-12-19 00:04:19 +03:00
Alexey Milovidov
84016cc96f Fixed error [#CLICKHOUSE-2]. 2017-12-18 09:39:07 +03:00
Alexey Milovidov
c5d5296889 Miscellaneous [#CLICKHOUSE-2]. 2017-12-18 07:07:26 +03:00
Alexey Milovidov
7c802ee3de Better semantic of sharing columns: development [#CLICKHOUSE-2]. 2017-12-18 05:37:08 +03:00
Alexey Milovidov
f95ddfce10 Make DataTypes totally immutable [#CLICKHOUSE-2]. 2017-12-18 04:11:48 +03:00
Alexey Milovidov
32bc1df714 Better semantic of sharing columns: development [#CLICKHOUSE-2]. 2017-12-17 13:51:19 +03:00
Alexey Milovidov
7d69e041f5 Better semantic of sharing columns: development [#CLICKHOUSE-2]. 2017-12-16 09:02:54 +03:00
Alexey Milovidov
278f8b9fcb Better semantic of sharing columns: development [#CLICKHOUSE-2]. 2017-12-16 08:52:47 +03:00
Alexey Milovidov
ddfb1fab9e Better semantic of sharing columns: development [#CLICKHOUSE-2]. 2017-12-16 08:46:46 +03:00
Alexey Milovidov
bce801a663 Better semantic of sharing columns: development [#CLICKHOUSE-2]. 2017-12-16 08:34:07 +03:00
Alexey Milovidov
14b0397500 Better semantic of sharing columns: development [#CLICKHOUSE-2]. 2017-12-16 08:21:04 +03:00
Alexey Milovidov
45805a367f Better semantic of sharing columns: development [#CLICKHOUSE-2]. 2017-12-16 07:59:32 +03:00
Alexey Milovidov
5b32914089 Better semantic of sharing columns: development [#CLICKHOUSE-2]. 2017-12-16 07:29:34 +03:00
Alexey Milovidov
3f0c4bf61c Better semantic of sharing columns: development [#CLICKHOUSE-2]. 2017-12-16 05:34:02 +03:00
Alexey Milovidov
30639dea0f Better semantic of sharing columns: development [#CLICKHOUSE-2]. 2017-12-16 05:24:02 +03:00
Alexey Milovidov
3e3042f01a Better semantic of sharing columns: development [#CLICKHOUSE-2]. 2017-12-16 04:21:59 +03:00
Alexey Milovidov
7284a64740 Better semantic of sharing columns: development [#CLICKHOUSE-2]. 2017-12-16 00:32:25 +03:00
Alexey Milovidov
ecd56de6a8 Better semantic of sharing columns: development [#CLICKHOUSE-2]. 2017-12-16 00:11:24 +03:00
Alexey Milovidov
b2aff7521b Better semantic of sharing columns: development [#CLICKHOUSE-2]. 2017-12-15 06:47:43 +03:00
Alexey Milovidov
401fd2d6d8 Better semantic of sharing columns: development [#CLICKHOUSE-2]. 2017-12-15 05:36:40 +03:00
Alexey Milovidov
fb38ef9a8e Better semantic of sharing columns: development [#CLICKHOUSE-2]. 2017-12-14 06:56:56 +03:00
Alexey Milovidov
bed2d644e6 Merge remote-tracking branch 'origin/master' into cow_columns 2017-12-14 04:44:35 +03:00
Alexey Milovidov
f3bb24a3bf Better semantic of sharing columns: development [#CLICKHOUSE-2]. 2017-12-14 04:43:19 +03:00
Alexey Milovidov
0dd0d76b19 Added changes from proller [#CLICKHOUSE-2]. 2017-12-14 00:09:31 +03:00
Alexey Milovidov
4d40879135 Proper fix for external dictionaries with complex keys [#CLICKHOUSE-2]. 2017-12-13 23:40:03 +03:00
Alexey Milovidov
819287b697 Better semantic of sharing columns: development [#CLICKHOUSE-2]. 2017-12-13 04:27:53 +03:00
Alexey Milovidov
7d04e67262 Merge branch 'write-buffer-from-arena' 2017-12-11 21:25:03 +03:00
Alexey Milovidov
3b65d95525 Translated comments and by the way made code better [#CLICKHOUSE-2]. 2017-12-11 21:05:16 +03:00
Alexey Milovidov
c3015bece3 Miscellaneous [#CLICKHOUSE-2]. 2017-12-11 01:44:04 +03:00
artpaul
b46ce4eca9 silence unused parameters 2017-12-10 00:31:05 +03:00
Alexey Milovidov
6a568ab692 Technically allowed empty arrays of unspecified type [#CLICKHOUSE-2]. 2017-12-09 23:56:53 +03:00
Alexey Milovidov
b34cdeec79 Fixed error [#CLICKHOUSE-2] 2017-12-09 19:17:37 +03:00
Alexey Milovidov
6ecc93e607 Fixed error [#CLICKHOUSE-2] 2017-12-09 19:17:37 +03:00
Alexey Milovidov
dd40e00f86 Fixed error [#CLICKHOUSE-2] 2017-12-09 19:17:37 +03:00
Alexey Milovidov
291467647a Cleanup semantics of data types [#CLICKHOUSE-2]. 2017-12-09 19:17:37 +03:00
Alexey Milovidov
44bcae8cce Simplification of Nullable [#CLICKHOUSE-2] 2017-12-09 19:17:37 +03:00
Alexey Milovidov
ae3d44f30f Cleanup semantics of data types [#CLICKHOUSE-2]. 2017-12-09 19:17:37 +03:00
Alexey Milovidov
3def5f03f5 Cleanup semantics of data types [#CLICKHOUSE-2]. 2017-12-09 19:17:37 +03:00
Alexey Milovidov
7f6c48d5de Cleanup semantics of data types [#CLICKHOUSE-2]. 2017-12-09 19:17:37 +03:00
Alexey Milovidov
d2cfda4d9b Cleanup semantics of data types [#CLICKHOUSE-2]. 2017-12-09 19:17:37 +03:00
Alexey Milovidov
42d1cbd6c7 Simplification of Nullable [#CLICKHOUSE-2] 2017-12-08 10:34:24 +03:00
Alexey Milovidov
09ddf5e21d Simplification of Nullable [#CLICKHOUSE-2] 2017-12-08 10:12:00 +03:00
Alexey Milovidov
f85afb3986 Simplification of Nullable [#CLICKHOUSE-2] 2017-12-08 09:46:35 +03:00
Alexey Milovidov
fcf371a930 Simplification of Nullable [#CLICKHOUSE-2] 2017-12-08 07:52:38 +03:00
Alexey Milovidov
c4a09a11f4 Simplification of Nullable [#CLICKHOUSE-2] 2017-12-08 06:52:33 +03:00
Alexey Milovidov
aefeee5697 Simplification of Nullable [#CLICKHOUSE-2] 2017-12-08 05:00:11 +03:00
Alexey Milovidov
00a7209607 Simplification of Nullable [#CLICKHOUSE-2] 2017-12-08 04:34:52 +03:00
Alexey Milovidov
741a6e0066 Simplification of Nullable [#CLICKHOUSE-2] 2017-12-08 03:50:25 +03:00
Alexey Milovidov
8cc0bae1bc Simplification of Nullable [#CLICKHOUSE-2] 2017-12-08 02:07:41 +03:00
Alexey Milovidov
d9c87bf4df Simplification of Nullable [#CLICKHOUSE-2] 2017-12-08 01:11:51 +03:00
Alexey Milovidov
be72c247fe Simplification of Nullable [#CLICKHOUSE-2] 2017-12-07 15:09:55 +03:00
Alexey Milovidov
0ea105f639 Simplification of Nullable [#CLICKHOUSE-2] 2017-12-07 11:31:47 +03:00
Alexey Milovidov
20151285e0 Simplification of Nullable [#CLICKHOUSE-2] 2017-12-07 08:53:23 +03:00
Alexey Milovidov
8204d2cdfd Simplification of Nullable [#CLICKHOUSE-2] 2017-12-07 06:50:43 +03:00
Alexey Milovidov
06f99aa25c Simplification of Nullable [#CLICKHOUSE-2] 2017-12-07 04:57:26 +03:00
Alexey Milovidov
ad10cb35bd Simplification of Nullable [#CLICKHOUSE-2] 2017-12-07 04:43:06 +03:00
Alexey Milovidov
2c1d7ad343 Simplification of Nullable [#CLICKHOUSE-2] 2017-12-07 03:31:46 +03:00
Alexey Milovidov
10c605042a Better [#CLICKHOUSE-2]. 2017-12-02 06:36:52 +03:00
Alexey Milovidov
db9b46ed72 Better [#CLICKHOUSE-2]. 2017-12-02 06:34:45 +03:00
Alexey Milovidov
ce8352b9cc Better [#CLICKHOUSE-2]. 2017-12-02 06:33:15 +03:00
Alexey Milovidov
7b3ce9085a Better [#CLICKHOUSE-2]. 2017-12-02 06:31:40 +03:00
Alexey Milovidov
3076b2c0eb Better [#CLICKHOUSE-2]. 2017-12-02 06:29:35 +03:00
Alexey Milovidov
c748493a86 Better [#CLICKHOUSE-2]. 2017-12-02 05:47:12 +03:00
Alexey Milovidov
7196602e12 Better [#CLICKHOUSE-2]. 2017-12-02 00:51:50 +03:00
Alexey Milovidov
54e601019c Better [#CLICKHOUSE-2]. 2017-12-02 00:40:58 +03:00
Alexey Milovidov
431da20d99 Better [#CLICKHOUSE-2]. 2017-12-01 23:21:35 +03:00
Alexey Milovidov
bdd25b15bd Better [#CLICKHOUSE-2]. 2017-12-01 22:34:51 +03:00
alexey-milovidov
3a0e0173ab
Merge pull request #1545 from samael500/master
Fix integer overflow
2017-11-25 01:43:48 +03:00
proller
6ff1968196 Compile and likk optimize and fixes 2017-11-24 21:08:01 +03:00
proller
0d3c4f4d67 Core/FieldVisitors.h -> Common/FieldVisitors.h
Core/Progress.h -> IO/Progress.h
    tests: sudo --non-interactive
    Fix freebsd link
2017-11-24 16:55:31 +03:00
Maks Skorokhod
d5cdfa6a48
🔧 fix typeowerflow on gcd and modulo functions 2017-11-24 11:17:49 +03:00
Maks Skorokhod
a06ca9cb82
:octocat: merge with master 2017-11-23 11:57:10 +03:00
Maks Skorokhod
e0f981f48c
🔧 correct type cast for LCM result 2017-11-23 11:40:06 +03:00
Alexey Milovidov
4bf120b285 Miscellaneous [#CLICKHOUSE-2]. 2017-11-23 05:11:16 +03:00
Alexey Milovidov
d2c900cdcc Fixed error (static initializers became too complex) [#CLICKHOUSE-2]. 2017-11-23 00:08:14 +03:00
Alexey Milovidov
df95b81196 Fixed error (static initializers became too complex) [#CLICKHOUSE-2]. 2017-11-22 23:53:47 +03:00
Maks Skorokhod
6b5fafbf73 🔁 add gcd and lcm to generate functions 2017-11-22 22:42:16 +03:00
Maks Skorokhod
f4489f17fc 🔧 use correct result types 2017-11-22 22:42:16 +03:00
Maks Skorokhod
25509e2ee2 🔁 add GCD and LCM functions support 2017-11-22 22:42:16 +03:00
Maks Skorokhod
a6f1707158
🔁 add gcd and lcm to generate functions 2017-11-22 13:48:59 +03:00
Maks Skorokhod
f09855e6f8
🔧 use correct result types 2017-11-22 12:50:23 +03:00
Maks Skorokhod
c31fd8ba88
🔁 add GCD and LCM functions support 2017-11-22 12:25:36 +03:00
Alexey Milovidov
a7d4fef0d2 Removed useless code [#CLICKHOUSE-2]. 2017-11-20 07:21:14 +03:00
Alexey Milovidov
60825748d4 Merge branch 'fix11' of https://github.com/proller/ClickHouse into proller-fix11 2017-11-19 22:57:28 +03:00
Alexey Milovidov
14e069f748 Allow to extract empty matches in "extractAll" function #1493. 2017-11-18 05:48:11 +03:00
Alexey Milovidov
8517251ebd Improved performance of toString function of Date and DateTime arguments [#CLICKHOUSE-2]. 2017-11-18 02:45:49 +03:00
proller
aa3dd03389 Split lib dbms to dbms + dbms_common_io 2017-11-17 22:19:49 +03:00
Alexey Milovidov
28b5bd8821 Removed useless code [#CLICKHOUSE-3431]. 2017-11-16 22:04:07 +03:00
Иванов Евгений
48636ac601 Added support UUID type for dictionaries 2017-11-15 23:31:53 +03:00
Alexander Makarov
5b113df16c Rewrote pieces of code with ambiguous '&pointer[offset]' semantics 2017-11-15 22:22:32 +03:00
Alexey Milovidov
8d3da74aae Fixed error [#CLICKHOUSE-2]. 2017-11-15 05:24:05 +03:00
Alexey Milovidov
fb2d2d36e0 Merge branch 'master' of github.com:yandex/ClickHouse 2017-11-14 20:08:55 +03:00
Alexey Milovidov
e6ccb9b662 Renamed function "runningIncome" to "runningDifferenceStartingWithFirstValue" for clarity [#CLICKHOUSE-2]. 2017-11-14 20:08:51 +03:00
Alexey Milovidov
18cdec38bd Added comment [#CLICKHOUSE-2]. 2017-11-14 01:53:14 +03:00
Alexey Milovidov
4c2ffbb315 Better implementations of isInfinite, isFinite, isNaN [#CLICKHOUSE-2]. 2017-11-14 00:47:49 +03:00
Alexey Milovidov
ac1b69247c Addition to prev. revision [#CLICKHOUSE-3402]. 2017-11-09 22:25:21 +03:00
Alexey Milovidov
62a5c882a9 Fixed error [#CLICKHOUSE-3402]. 2017-11-09 22:25:21 +03:00
Alexey Milovidov
2d1702f8e6 Added test for enhanced time zones support [#CLICKHOUSE-3402]. 2017-11-09 22:25:21 +03:00
Alexey Milovidov
60477a9aaa Enhanced time zones support: the DateTime data type can track time zone [#CLICKHOUSE-3402]. 2017-11-09 22:25:21 +03:00
Alexey Milovidov
8e4253ac73 Fixed error when Date argument can be passed to toStartOfDay function [#CLICKHOUSE-2]. 2017-11-05 08:17:48 +03:00
Nikolai Kochetov
c8d4a92cfb added runningIncome [#CLICKHOUSE-3395] 2017-10-31 17:27:02 +03:00
alexey-milovidov
56ef2e9196
Merge pull request #1380 from yandex/catboost-models
Catboost models
2017-10-30 19:16:41 +03:00
Alexey Milovidov
7a876fddb9 Attempt to fix build with gcc 6 [#CLICKHOUSE-2]. 2017-10-30 17:00:47 +03:00
Alexey Milovidov
b7e006213b Removed obsolete test [#CLICKHOUSE-2]. 2017-10-30 09:10:57 +03:00
Alexey Milovidov
ad8afcc022 Added functions to implement INTERVAL operations [#CLICKHOUSE-3393]. 2017-10-30 08:39:30 +03:00
Alexey Milovidov
bed7b531a1 INTERVAL operators: development [#CLICKHOUSE-3393]. 2017-10-30 08:39:30 +03:00
Alexey Milovidov
5c8c3bdde0 Fixed build on Mac OS X [#CLICKHOUSE-2]. 2017-10-29 08:52:41 +03:00
Alexey Milovidov
7ecc63fe71 Functions for interval arithmetic on DateTime and Date: development [#CLICKHOUSE-2]. 2017-10-29 07:18:48 +03:00
Alexey Milovidov
4236bcbfa2 Fixed year 2038 problem. Added support for timezones with fractional offset from UTC. [#CLICKHOUSE-2099] [#CLICKHOUSE-3392]. 2017-10-29 03:51:40 +03:00
Alexey Milovidov
6ca1b84929 Added function getSizeOfEnumType [#CLICKHOUSE-2]. 2017-10-27 23:39:49 +03:00
Vitaliy Lyudvichenko
cd5d1d5009 Fixed segfault in compare operators with Nullable types. #1416 [#CLICKHOUSE-3] 2017-10-27 23:03:12 +03:00
Nikolai Kochetov
3757c9682e style fixes [#CLICKHOUSE-3305] 2017-10-26 21:49:23 +03:00
Alexey Milovidov
a27981b4ef Get rid of double whitespaces [#CLICKHOUSE-2]. 2017-10-26 21:36:23 +03:00
Nikolai Kochetov
092567af39 changed CatBoost model evaluate signature [#CLICKHOUSE-3305] 2017-10-26 17:10:51 +03:00
proller
4ffbca2d8c Fix warnings (#1406)
* Log query id in executeQuery; Better type mismatch error; change format in report tool

* Better log query_id

* fix message

* Use c++11 thread_local instaed of gcc's __thread

* lock mutex before notifying waiting thread in sync insertion into distributed [#CLICKHOUSE-3379]

* Cmake: fix build without downloaded submodules (#1379)

* fix

* ZooKeeper: fixed stack smashing with tryGet()

The tryGet() operation creates a 1MB buffer on stack. This may or
may not work depending on the default stack size for threads,
whether the stack protector is enabled or not, recursion depth,
and the actual value size.

This is probably going to slow down some ZK operations, but I don't
see how else this could work reliably with the existing API.

* increased timeout for test_insertion_sync_fails_with_timeout

* Update CHANGELOG_RU.md

* Update ZooKeeper.cpp

* Fix warnings

* Fixes

* Dont strip debug info from  asan, tsan and other builds except releases

* Fix asan error causd by test 00144

* Fix empty log message (#CLICKHOUSE-3378)
2017-10-25 21:39:10 +03:00
proller
2d2a4afa3f Fix stripping debug info from huge .o (-g0) 2017-10-24 16:30:44 +03:00
Nikolai Kochetov
74a4c7508a merged with master 2017-10-20 19:18:09 +03:00
Nikolai Kochetov
e23e15dba8 fix arguments count in FunctionModelEvaluate [#CLICKHOUSE-3305] 2017-10-20 19:13:29 +03:00
Nikolai Kochetov
48de8de6e0 added registerFunctionsExternalModels [#CLICKHOUSE-3305] 2017-10-20 19:13:28 +03:00
Nikolai Kochetov
fdf258f8ed added ExternalModels to Context [#CLICKHOUSE-3305]
fix build [#CLICKHOUSE-3305]

fix build [#CLICKHOUSE-3305]

fix build [#CLICKHOUSE-3305]

fix build [#CLICKHOUSE-3305]

fix build [#CLICKHOUSE-3305]
2017-10-20 19:13:25 +03:00
Nikolai Kochetov
bb4547140b added ExternalModels, applyModel [#CLICKHOUSE-3305] 2017-10-20 19:13:21 +03:00
Marek Vavruša
70543200be dbms: Fix build with clang after Poco update
In the current version of Poco, unsigned long no longer aliases to
UInt64 with LP64. The size_t aliases to unsigned long with clang,
so all the uses of size_t instead of UInt64 when interacting with
Poco interfaces are gone. I replaced uses with UInt64 where it makes
sense, and added an overloaded function for readVarUInt() to support size_t.
2017-10-13 18:26:24 -07:00
alexey-milovidov
9ccdb5420b Merge branch 'master' into upstream-add-kafka 2017-10-13 23:52:42 +03:00
proller
fd85fffa0d Fix compile CallPointInPolygon on clang4 (Thanks to @vavrusa) (#1333)
* Fix compile with boost 1.65.1+ and clang 3.8 ( https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=222439 )

* Fix compile CallPointInPolygon on clang4 (Thanks to @vavrusa)
2017-10-13 00:22:04 +03:00
proller
3de5e465d0 Split GatherUtils.cpp for faster compile (#1312)
* Split GatherUtils.cpp for faster compile

* remove GatherUtils.cpp
2017-10-12 22:58:39 +03:00
Marek Vavruša
cbf9aaca95 dbms: fixed minor mistakes with build
* Use std::abs instead of abs() to properly support floats
2017-10-10 08:32:42 -07:00
proller
5250650f65 Fixes (#1286)
* Revert "Simplification [#CLICKHOUSE-2]."

This reverts commit 98ad6a5db3.

* Fix error: comparison of unsigned expression < 0 is always false

* Fix float division by zero

* Fix float division by zero

* Disable PointInPolygon function if compiling with old clang

* Fix warning:
dbms/src/Functions/FunctionsCoding.h:336:21: error: comparison of constant -1 with expression of type 'const char' is always true [-Werror,-Wtautological-constant-out-of-range-compare]
            if (num != -1)

* Fix
2017-09-26 23:29:34 +03:00
Nikolai Kochetov
1592691e47 fixed defalut Nullable implementation for Const(Nullable) columns 2017-09-26 20:34:48 +03:00
Nikolai Kochetov
c8ffca746e fixed defalut Nullable implementation for Const(Nullable) columns [#CLICKHOUSE-3339] 2017-09-26 20:34:48 +03:00
Nikolai Kochetov
c8dc25815f fixed pointinPolygon test, clang build 2017-09-26 19:07:00 +03:00
proller
ed848a7186 Fix warning on arm 2017-09-24 16:59:18 +03:00
KochetovNicolai
6096227cb2 Point in polygon (#1269)
* added FunctionPointInPolygonWithGrid [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix PointInPolygonWithGrid [#CLICKHOUSE-3201]

* fix PointInPolygonWithGrid [#CLICKHOUSE-3201]

* fix PointInPolygonWithGrid [#CLICKHOUSE-3201]

* fix PointInPolygonWithGrid [#CLICKHOUSE-3201]

* added test for PointInPolygonWithGrid [#CLICKHOUSE-3201]

* added test for PointInPolygonWithGrid with holes [#CLICKHOUSE-3201]

* added arbitrary orientation for polygons in PointInPolygonWithGrid [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix arbitrary orientation for polygons in PointInPolygonWithGrid [#CLICKHOUSE-3201]

* added test for arbitrary orientation for polygons in PointInPolygonWithGrid [#CLICKHOUSE-3201]

* fixed shifted grid for PointInPolygonWithGrid, added test [CLICKHOUSE-3201]

* expand box for complex polygons in PointInPolygonWithGrid [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* fix expand box for complex polygons in PointInPolygonWithGrid [#CLICKHOUSE-3201]

* added pool to PointInPolygonWithGrid [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* changed FunctionPointInPolygonWithGrid signature [#CLICKHOUSE-3201]

* changed FunctionPointInPolygonWithGrid signature [#CLICKHOUSE-3201]

* fixed test [#CLICKHOUSE-3201]

* unified signature for PointInPolygon [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* supported Float64 for pointInPolygon [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fixed check for numeric tuple in PointInPolygon function [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* added profile events polygons pool [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* Update FunctionsGeo.cpp

* made grid_size argument of PointInPolygon; style fixes [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* renamed pointInPolygon functions [#CLICKHOUSE-3201]
2017-09-24 02:47:43 +03:00
KochetovNicolai
e0efb7e8c1 Point in polygon (#1264)
* added FunctionPointInPolygonWithGrid [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix PointInPolygonWithGrid [#CLICKHOUSE-3201]

* fix PointInPolygonWithGrid [#CLICKHOUSE-3201]

* fix PointInPolygonWithGrid [#CLICKHOUSE-3201]

* fix PointInPolygonWithGrid [#CLICKHOUSE-3201]

* added test for PointInPolygonWithGrid [#CLICKHOUSE-3201]

* added test for PointInPolygonWithGrid with holes [#CLICKHOUSE-3201]

* added arbitrary orientation for polygons in PointInPolygonWithGrid [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix arbitrary orientation for polygons in PointInPolygonWithGrid [#CLICKHOUSE-3201]

* added test for arbitrary orientation for polygons in PointInPolygonWithGrid [#CLICKHOUSE-3201]

* fixed shifted grid for PointInPolygonWithGrid, added test [CLICKHOUSE-3201]

* expand box for complex polygons in PointInPolygonWithGrid [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* fix expand box for complex polygons in PointInPolygonWithGrid [#CLICKHOUSE-3201]

* added pool to PointInPolygonWithGrid [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* changed FunctionPointInPolygonWithGrid signature [#CLICKHOUSE-3201]

* changed FunctionPointInPolygonWithGrid signature [#CLICKHOUSE-3201]

* fixed test [#CLICKHOUSE-3201]

* unified signature for PointInPolygon [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* supported Float64 for pointInPolygon [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fix build [#CLICKHOUSE-3201]

* fixed check for numeric tuple in PointInPolygon function [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* added profile events polygons pool [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* fixed build [#CLICKHOUSE-3201]

* Update FunctionsGeo.cpp
2017-09-20 05:30:44 +03:00
Alexey Milovidov
565902fc4d Added comment; fixed test [#CLICKHOUSE-2]. 2017-09-17 20:58:30 +03:00
Alexey Milovidov
a5e8c5e8f5 Better [#CLICKHOUSE-2]. 2017-09-17 01:24:48 +03:00
Alexey Milovidov
b80788a2f4 Better implementation of "roundToExp2" function [#CLICKHOUSE-2]. 2017-09-17 01:12:24 +03:00
Alexey Milovidov
5224345c03 Added function aliases for 'trunc' [#CLICKHOUSE-2]. 2017-09-17 01:11:20 +03:00
Alexey Milovidov
c2595934f1 FunctionsRound: continue [#CLICKHOUSE-2]. 2017-09-16 23:17:19 +03:00
Alexey Milovidov
d48725f9a7 FunctionsRound: continue [#CLICKHOUSE-2]. 2017-09-16 22:33:49 +03:00
Alexey Milovidov
84d61b501c FunctionsRound: continue [#CLICKHOUSE-2]. 2017-09-16 22:31:20 +03:00
Alexey Milovidov
ad13a8c79d Fixed half of bad code [#CLICKHOUSE-2]. 2017-09-16 21:36:16 +03:00
Alexey Milovidov
0002507598 Added function "trunc"; simplifications [#CLICKHOUSE-2]. 2017-09-16 19:47:05 +03:00
Alexey Milovidov
25f2f032d1 Added function "trunc"; simplifications [#CLICKHOUSE-2]. 2017-09-16 19:38:27 +03:00
Alexey Milovidov
86c46ad1bd Unification [#CLICKHOUSE-2]. 2017-09-15 15:16:12 +03:00
Nikolai Kochetov
2bb487c333 fixed string concat wih first array argument in block 2017-09-13 22:33:47 +03:00
Alexey Milovidov
dc4976f562 Implemented some suggestions from clang-tidy (part 8) [#CLICKHOUSE-3301]. 2017-09-08 07:58:57 +03:00
Alexey Milovidov
8b313ab99e Fixed warnings found by cppcheck [#CLICKHOUSE-3300]. 2017-09-08 00:04:48 +03:00
Alexey Milovidov
0dcee75180 Supporessed useless false positive errors found by cppcheck [#CLICKHOUSE-3300]. 2017-09-07 22:13:37 +03:00
Vadim Skipin
4017622ffb CLICKHOUSE-3289: Do not use Application singleton 2017-09-07 20:55:33 +03:00
Alexey Milovidov
b370551e67 Fixed redundant code in IPv4NumToStringClassC function and removed copy-paste [#CLICKHOUSE-3281]. 2017-09-06 06:24:39 +03:00
Alexey Milovidov
ff8940ddbe Fixed bad code [#CLICKHOUSE-3281]. 2017-09-06 06:24:39 +03:00
Alexey Milovidov
60263d943e IPv6StringToNum: fixed missing overflow check [#CLICKHOUSE-3281]. 2017-09-06 06:24:39 +03:00
Alexey Milovidov
24ac5a68e1 More uniform style [#CLICKHOUSE-3281]. 2017-09-06 06:24:39 +03:00
Alexey Milovidov
ee469f7a98 Fixed redundant code [#CLICKHOUSE-3281]. 2017-09-06 06:24:39 +03:00
Alexey Milovidov
3b6dd67178 Fixed nullptr dereference [#CLICKHOUSE-3281]. 2017-09-06 06:24:39 +03:00
Alexey Milovidov
b37790d27e Minor modifications [#CLICKHOUSE-3201]. 2017-09-04 23:21:55 +03:00
Vladimir Chebotarev
e39fb48377 functions: pointInPolygon(). [#CLICKHOUSE-3201] 2017-09-04 17:26:28 +03:00
alexey-milovidov
223ebc0b0d Merge pull request #1187 from yandex/array-functions-concat-slice-push-pop
Fix array functions for generic array type
2017-09-01 21:11:09 +03:00
Nikolai Kochetov
20766debb0 fix arrasSlice for gereric arrays [#CLICKHOUSE-2090] 2017-09-01 21:01:06 +03:00
Nikolai Kochetov
32ed1b0b41 fix arrasSlice for gereric arrays [#CLICKHOUSE-2090] 2017-09-01 20:41:43 +03:00
alexey-milovidov
897a9ad6b2 Merge pull request #1146 from yandex/array-functions-concat-slice-push-pop
Array functions concat slice push pop
2017-09-01 20:30:51 +03:00
proller
1a8e22c37f Allow compile on 32bit systems (#1175)
* Trying compile under 32bit..

* PerformanceTest: use getMultiple*FromConfig, fix debug helpers

* Missing file

* clnag-format of Split ComplexKeyCacheDictionary

* wip

* Requested changes

* wip

* wip

* Fix boost 1.64 and gcc7+ compile errors

* More fixes

* wip

* Fix arm build

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* clean

* fix

* wip

* wip

* clean

* clean

* wip

* wip

* Update MergeTreeSettings.h

* Requested changes

* Requested changes

* Requested changes

* Requested changes
2017-09-01 20:21:03 +03:00
Nikolai Kochetov
463c05b33d fixed build [#CLICKHOUSE-2090] 2017-09-01 20:16:48 +03:00
Nikolai Kochetov
a88bb9375a removed useless code from GatherUtils [#CLICKHOUSE-2090] 2017-09-01 20:14:47 +03:00
Nikolai Kochetov
df09912864 reformated GatherUtils.cpp [#CLICKHOUSE-2090] 2017-09-01 20:07:58 +03:00
Nikolai Kochetov
b4f7e0e15c restored identation in FunctionsArray.cpp [#CLICKHOUSE-2090] 2017-09-01 19:57:01 +03:00
Nikolai Kochetov
a46780e4a5 renamed concatGeneric to concatGenericArray [#CLICKHOUSE-2090] 2017-09-01 19:45:05 +03:00
Nikolai Kochetov
3370ba270f fix build [#CLICKHOUSE-2090] 2017-09-01 17:55:43 +03:00
Nikolai Kochetov
862460f293 changed & to && in GatherUtils.cpp [#CLICKHOUSE-2090] 2017-09-01 17:47:42 +03:00
Nikolai Kochetov
b392788e86 fix build [#CLICKHOUSE-2090] 2017-09-01 17:35:37 +03:00
Nikolai Kochetov
5b4759acd9 changed sibstring behaviour for offset < -string_lenght [#CLICKHOUSE-2090] 2017-09-01 17:32:12 +03:00
Nikolai Kochetov
f1c01118b5 fixed writeSlice for const GenericArraySlice and NumericArraySink [#CLICKHOUSE-2090] 2017-09-01 16:55:05 +03:00
Nikolai Kochetov
6956e12770 added comments to writeSlice functions [#CLICKHOUSE-2090] 2017-09-01 16:03:54 +03:00
Nikolai Kochetov
1da43b683c fixed comment [#CLICKHOUSE-2090] 2017-09-01 15:23:06 +03:00
Nikolai Kochetov
7885c5c032 renamed TypeListNumber to TypeListNumbers [#CLICKHOUSE-2090] 2017-09-01 15:09:08 +03:00
Nikolai Kochetov
7891596579 unified TypeList [#CLICKHOUSE-2090] 2017-09-01 15:05:19 +03:00
Nikolai Kochetov
c695f10c66 hanged & to && in GatherUtils [#CLICKHOUSE-2090] 2017-09-01 14:32:31 +03:00
Nikolai Kochetov
c0b05f2ca9 hanged & to && in GatherUtils [#CLICKHOUSE-2090] 2017-09-01 14:02:26 +03:00
alexey-milovidov
1b8100ae86 Update FunctionsArray.cpp 2017-08-31 20:00:51 +03:00
alexey-milovidov
c6f87d9543 Update GatherUtils.h 2017-08-31 19:24:46 +03:00
Nikolai Kochetov
24e135fbe6 supported arraySlice with 2 arguments, added comments [#CLICKHOUSE-2090] 2017-08-25 16:54:08 +03:00
Nikolai Kochetov
1ec04d1024 supported || for arrayConcat [#CLICKHOUSE-2090] 2017-08-25 16:05:26 +03:00
Nikolai Kochetov
239f4f2d36 merged with master 2017-08-25 15:05:18 +03:00
Nikolai Kochetov
0f4e7f1833 fixed array slice with offset <= -(array length) [#CLICKHOUSE-2090] 2017-08-25 14:29:49 +03:00
Nikolai Kochetov
d213efa974 fixed slice for nullable index [#CLICKHOUSE-2090] 2017-08-24 22:19:37 +03:00
Nikolai Kochetov
d8529e1846 unused type alias [#CLICKHOUSE-2090] 2017-08-24 21:16:25 +03:00
Nikolai Kochetov
09a307b94f removed debug stderr output [#CLICKHOUSE-2090] 2017-08-24 19:46:41 +03:00
Nikolai Kochetov
e6fd55ff42 added arrayPushBack arrayPushFront arrayPopBack arrayPopFront function [#CLICKHOUSE-2090] 2017-08-24 19:46:40 +03:00
Nikolai Kochetov
096d34bb7f added arraySlice function [#CLICKHOUSE-2090] 2017-08-24 19:46:34 +03:00
Nikolai Kochetov
c1479a5594 updated GatherUtils [#CLICKHOUSE-2090] 2017-08-24 19:46:15 +03:00
Nikolai Kochetov
c3fe8bb026 added FunctionArrayConcat [#CLICKHOUSE-2090] 2017-08-24 19:45:13 +03:00
Alexey Milovidov
304ccf29b2 Fixed error; added test [#CLICKHOUSE-2]. 2017-08-18 22:02:50 +03:00
Alexey Milovidov
5d835e88de Merge branch 'master' of github.com:yandex/ClickHouse 2017-08-18 21:45:10 +03:00
Alexey Milovidov
434a7d8f38 Fixed function "substring" with out-of-bound negative offset argument [#CLICKHOUSE-2]. 2017-08-18 21:45:02 +03:00
Vadim Skipin
5f4e833925 Cleanup function factories:
* Switch to std::function to allow more complex creator logic
* Cleanup headers
2017-08-18 21:15:57 +03:00
Alexey Milovidov
f918e22438 Miscellaneous [#CLICKHOUSE-2]. 2017-08-18 19:36:02 +03:00
Alexey Milovidov
c629799500 Fixed insufficient arguments checking [#CLICKHOUSE-3102]. 2017-08-16 17:21:24 +03:00
Alexey Milovidov
2ddf462563 Fixed regression [#CLICKHOUSE-2]. 2017-08-16 00:52:52 +03:00
Alexey Milovidov
986c6c729d Fixed incompatibility [#CLICKHOUSE-2]. 2017-08-14 07:23:38 +03:00
Alexey Milovidov
0ef64e5dfe Fixed error [#CLICKHOUSE-2]. 2017-08-14 02:58:04 +03:00
Alexey Milovidov
1e1dc8828a Miscellaneous [#CLICKHOUSE-2]. 2017-08-13 00:02:45 +03:00
Alexey Milovidov
ce4349b6cd Fixed error when huge sets for IN, JOIN, DISTINCT cannot be created with exception message "Cannot mremap... Bad address" [#CLICKHOUSE-2]. 2017-08-11 02:25:51 +03:00
alexey-milovidov
a122cd613a Update FunctionsExternalDictionaries.h 2017-08-10 06:29:06 +03:00
proller
6ca798a357 Fix infinite loop in dictGetHierarchy if id chain looped 2017-08-10 06:29:06 +03:00
proller
ac178bde1f Cmake: link ltdl with pocoodbc static only. rename ARM -> ARCH_ARM (#1083)
* Cmake: link ltdl with pocoodbc static only. rename ARM -> ARCH_ARM

* Fix lib find order

* Allow define non-contrib cityhash farmhash metrohash

* Fix message

* Cmake: fixes

* clean

* Update CMakeLists.txt
2017-08-09 23:52:55 +03:00
Alexey Milovidov
6edb14ba6b Fixed garbage [#CLICKHOUSE-2]. 2017-08-09 04:35:12 +03:00
Alexey Milovidov
1fc8548018 Fixing garbage (incomplete) [#CLICKHOUSE-2]. 2017-08-09 04:35:12 +03:00
Alexey Milovidov
ff54c93a22 Miscellaneous [#CLICKHOUSE-2]. 2017-08-07 04:37:52 +03:00
Alexey Milovidov
f386788278 Using GatherUtils for function if on arguments of type Array(String) [#CLICKHOUSE-2]. 2017-08-05 07:13:23 +03:00
Alexey Milovidov
5ddc354989 Using GatherUtils for function if on arguments of type Array(String) [#CLICKHOUSE-2]. 2017-08-05 07:13:23 +03:00
Alexey Milovidov
19ff0db9f1 Using GatherUtils for if on numeric arrays [#CLICKHOUSE-2]. 2017-08-05 06:30:54 +03:00
Alexey Milovidov
6648d6dee4 Using GatherUtils for if on numeric arrays [#CLICKHOUSE-2]. 2017-08-05 06:30:54 +03:00
Alexey Milovidov
49bdf266b0 Fixed function if of FixedString arguments [#CLICKHOUSE-3202]. 2017-08-05 05:25:59 +03:00
Alexey Milovidov
03662e3d77 Fixed function if of FixedString arguments [#CLICKHOUSE-3202]. 2017-08-05 05:25:59 +03:00
Alexey Milovidov
dadf5ac400 Fixed function if of FixedString arguments [#CLICKHOUSE-3202]. 2017-08-05 05:25:59 +03:00
Alexey Milovidov
0bb8b32cb9 Fixed function if of FixedString arguments [#CLICKHOUSE-3202]. 2017-08-05 05:25:59 +03:00
Alexey Milovidov
767d025fb3 Fixed function if of FixedString arguments [#CLICKHOUSE-3202]. 2017-08-05 05:25:59 +03:00
proller
d6833a0d55 Cmake: remove global include_directories (#1055)
* Fix .h compile

* Cmake: remove global include_directories

* boost include hide

* fix cctz

* add \n
2017-08-03 15:44:39 +03:00
proller
8f6c2d4e47 Fix .h compile 2017-08-01 18:02:16 +03:00
Alexey Milovidov
a6cb383c4f Fixed build with gcc-7.1 [#CLICKHOUSE-2]. 2017-08-01 04:25:03 +03:00
Alexey Milovidov
6578fb2645 Fixed error [#CLICKHOUSE-3191]. 2017-08-01 00:39:24 +03:00
Alexey Milovidov
306070d2cc Fixed error in one of prev. revisions [#CLICKHOUSE-3150]. 2017-07-30 22:47:32 +03:00
proller
460d66c68d Split FunctionsArray.cpp register (#1043)
* PerformanceTest: use getMultiple*FromConfig, fix debug helpers

* Missing file

* gcc7 fixes

* clnag-format of Split ComplexKeyCacheDictionary

* Requested changes

* Fix boost 1.64 and gcc7+ compile errors

* More fixes

* Fix arm build

* Fix nothrow

* Better arm detection

* Split FunctionsArray.cpp register
2017-07-30 15:31:58 +03:00
proller
700d4e0904 Fix boost 1.64 and gcc7+ compile errors (#1040)
* PerformanceTest: use getMultiple*FromConfig, fix debug helpers

* Missing file

* clnag-format of Split ComplexKeyCacheDictionary

* Requested changes

* Fix boost 1.64 and gcc7+ compile errors

* More fixes
2017-07-28 23:41:51 +03:00
Alexey Milovidov
3502d36d7d Fixed build [#CLICKHOUSE-2]. 2017-07-28 02:23:13 +03:00
proller
ff7f3af238 Split FunctionsArithmetic.cpp to generated functions 2017-07-26 21:32:35 +03:00
Alexey Milovidov
3dcb2e6aed Fixed test [#CLICKHOUSE-2]. 2017-07-26 04:21:19 +03:00
Alexey Milovidov
d20c411b0d Fixed linkage [#CLICKHOUSE-2]. 2017-07-25 21:19:22 +03:00
Vitaliy Lyudvichenko
03e5bf9471 Add support of parameters in aggregate function constructors. [#CLICKHOUSE-3084] 2017-07-25 20:04:10 +03:00
Guillaume Tassery
03bbe9938a Function for generate an uuid v4 (#1008)
* Fix compilation error when include FunctionsRandom.h twice

* Implement function for generate UUID V4

* remove isDeterministicInScopeOfQuery for generateUUIDV4

* Uniformize RandX Implementation

* rename generateUUIDV4 into generateUUIDv4

* Modify random function for making it more generic
2017-07-25 20:00:38 +03:00
Alexey Milovidov
f153d5f5db Additions to prev. revision [#CLICKHOUSE-2]. 2017-07-25 01:53:44 +03:00
Alexey Milovidov
b4c610a8e7 Fixed errors [#CLICKHOUSE-2]. 2017-07-25 01:44:13 +03:00
Alexey Milovidov
188ee349bd Fixed errors [#CLICKHOUSE-2]. 2017-07-25 01:44:13 +03:00
Alexey Milovidov
a6df2e7151 Added support for non-constant and negative offset and size for substring function (continued) [#CLICKHOUSE-2]. 2017-07-25 01:44:13 +03:00
Alexey Milovidov
487278e2f5 Added support for non-constant and negative offset and size for substring function (continued) [#CLICKHOUSE-2]. 2017-07-25 01:44:13 +03:00
Alexey Milovidov
3144cbc9c1 Added support for non-constant and negative offset and size for substring function (continued) [#CLICKHOUSE-2]. 2017-07-25 01:44:13 +03:00
Alexey Milovidov
94768fe9bf Added support for non-constant and negative offset and size for substring function (continued) [#CLICKHOUSE-2]. 2017-07-25 01:44:13 +03:00
Alexey Milovidov
52b5bae62f Added support for non-constant and negative offset and size for substring function (continued) [#CLICKHOUSE-2]. 2017-07-25 01:44:13 +03:00
Alexey Milovidov
30ff4a78a6 Added support for non-constant and negative offset and size for substring function (continued) [#CLICKHOUSE-2]. 2017-07-25 01:44:13 +03:00
Alexey Milovidov
14de659c99 Added support for non-constant offset and size for substring function [#CLICKHOUSE-2]. 2017-07-25 01:44:13 +03:00
Alexey Milovidov
0c8e082954 Using GatherUtils (experimental) [#CLICKHOUSE-2]. 2017-07-25 01:44:13 +03:00
Alexey Milovidov
1557fa2e8d Removed "dispatchFor" templates, because gcc 6 cannot compile them (only clang is capable) [#CLICKHOUSE-2]. 2017-07-25 01:44:13 +03:00
Alexey Milovidov
ffbd2f46f9 GatherUtils (experimental) [#CLICKHOUSE-2]. 2017-07-25 01:44:13 +03:00
Alexey Milovidov
9540a2da90 GatherUtils (experimental) [#CLICKHOUSE-2]. 2017-07-25 01:44:13 +03:00
Alexey Milovidov
bfdc108a08 Cleaning old code [#CLICKHOUSE-2]. 2017-07-25 01:44:13 +03:00
Alexey Milovidov
ee81d53bd5 Functions simplification [#CLICKHOUSE-2]. 2017-07-25 01:44:13 +03:00
alexey-milovidov
bbe70e8cfa Update FunctionsStringSearch.cpp 2017-07-24 20:36:16 +03:00
Alexey Milovidov
efaa44bea8 Attempt to improve performance [#CLICKHOUSE-3]. 2017-07-23 09:53:28 +03:00
Alexey Milovidov
a76061e1a9 Fixed MAC address related functions; added test [#CLICKHOUSE-3]. 2017-07-23 09:13:57 +03:00
Alexey Milovidov
31d8ba3b34 Fixed error after merge [#CLICKHOUSE-3150]. 2017-07-21 23:20:22 +03:00
Nikolai Kochetov
5477e7c1f9 added date and time to number functions [#CLICKHOUSE-3132] 2017-07-21 20:51:08 +03:00
Alexey Milovidov
3a0bf8e642 Fixed error after merge [#CLICKHOUSE-3150]. 2017-07-21 09:55:33 +03:00
Alexey Milovidov
e1cc8289b2 Fixed error after merge [#CLICKHOUSE-3150]. 2017-07-21 09:46:50 +03:00
alexey-milovidov
d4d266fa18 ColumnConst unification (#1011)
* ColumnConst: unification (incomplete) [#CLICKHOUSE-3150].

* ColumnConst: unification (incomplete) [#CLICKHOUSE-3150].

* ColumnConst: unification (incomplete) [#CLICKHOUSE-3150].

* ColumnConst: unification (incomplete) [#CLICKHOUSE-3150].

* ColumnConst: unification (incomplete) [#CLICKHOUSE-3150].

* ColumnConst: unification (incomplete) [#CLICKHOUSE-3150].

* ColumnConst: unification (incomplete) [#CLICKHOUSE-3150].

* ColumnConst: unification (incomplete) [#CLICKHOUSE-3150].

* ColumnConst: unification (incomplete) [#CLICKHOUSE-3150].

* ColumnConst: unification (incomplete) [#CLICKHOUSE-3150].

* ColumnConst: unification (incomplete) [#CLICKHOUSE-3150].

* ColumnConst: unification (incomplete) [#CLICKHOUSE-3150].

* ColumnConst: unification (incomplete) [#CLICKHOUSE-3150].

* ColumnConst: unification (incomplete) [#CLICKHOUSE-3150].

* Fixed error in ColumnArray::replicateGeneric [#CLICKHOUSE-3150].

* ColumnConst: unification (incomplete) [#CLICKHOUSE-3150].

* ColumnConst: unification (incomplete) [#CLICKHOUSE-3150].

* ColumnConst: unification (incomplete) [#CLICKHOUSE-3150].

* ColumnConst: unification (incomplete) [#CLICKHOUSE-3150].

* ColumnConst: unification (incomplete) [#CLICKHOUSE-3150].

* ColumnConst: unification (incomplete) [#CLICKHOUSE-3150].

* ColumnConst: unification (incomplete) [#CLICKHOUSE-3150].

* ColumnConst: unification (incomplete) [#CLICKHOUSE-3150].

* ColumnConst: unification (incomplete) [#CLICKHOUSE-3150].

* ColumnConst: unification (incomplete) [#CLICKHOUSE-3150].

* ColumnConst: unification (incomplete) [#CLICKHOUSE-3150].

* ColumnConst: unification (incomplete) [#CLICKHOUSE-3150].

* ColumnConst: unification (incomplete) [#CLICKHOUSE-3150].
2017-07-21 09:35:58 +03:00
Vladimir Chebotarev
7254478fde functions: Remote mode for hasColumnInTable. [#CHEBOTAREV-9] 2017-07-20 17:08:42 +03:00
Alexey Milovidov
bfc099ea5f Miscellaneous [#CLICKHOUSE-2]. 2017-07-17 01:41:15 +03:00
Alexey Milovidov
5c3ca0c16e Inverted dependency in DataTypeFactory [#CLICKHOUSE-3149]. 2017-07-16 07:11:11 +03:00
Alexey Milovidov
9406b6a5aa Get rid of ASTSet, because it is not really an AST and it lead to bugs [#CLICKHOUSE-3148]. 2017-07-15 06:48:36 +03:00
alexey-milovidov
37985d3cb8 Merge pull request #981 from yandex/reduce-memory-consumprion-during-reading-column-string-from-native-block
Reduce memory consumprion during reading column string from native block
2017-07-14 00:01:50 +03:00
Nikolai Kochetov
75be0b81d8 removed typeid_cast from IColumn.h 2017-07-13 23:58:19 +03:00
Maxim Fridental
82b53b712a findClusterIndex: fix virtual method, improve formatting 2017-07-13 22:39:37 +03:00
Maxim Fridental
ff4df27cad Improve implementation of findClusterIndex and findClusterValue, add test 2017-07-13 22:39:37 +03:00
Nikolai Kochetov
985e449bd3 added IDataType::updateAvgValueSizeHints; renamed PODArray::allocated_size to PODArray::allocated_bytes; renamed renamed IColumn::allocatedSize to IColumn::allocatedBytes; removed IColumn.h from IDataType.h 2017-07-13 19:49:09 +03:00
Alexey Milovidov
33c6e0b804 Removing dependency on functions from client: preparation [#CLICKHOUSE-2]. 2017-07-12 03:42:50 +03:00
Vitaliy Lyudvichenko
b843ea5b3f Resolves #964. Fixed input_format_skip_unknown_fields for negative numbers. [#CLICKHOUSE-3] 2017-07-11 21:36:51 +03:00
Alexey Milovidov
86eb4d2d06 Renamed Singleton to avoid conflicts with Arcadia* codebase [#DEVTOOLS-3343].
* - "Arcadia" is the name of Yandex's monorepo.
2017-07-10 07:34:14 +03:00
alexey-milovidov
b64b243a73 Merge pull request #945 from YiuRULE/master
Implement natively uuid type in Clickhouse
2017-07-10 07:00:45 +03:00
alexey-milovidov
894d09f797 Update IFunction.h 2017-07-09 17:13:51 +03:00
Marek Vavruša
ff73394124 PKCondition: infer index use with pk subexpression
By default only constraints explicitly matching
primary key expression (or expression wrapped in
a monotonic function) are eligible for part and
range selection. So for example, if index is:

(toStartOfHour(dt), UserID)

Then a query such as this resorts to full scan:

SELECT count() FROM t WHERE dt = now()

Intuitively, only parts with toStartOfHour(now())
could be selected, but it is less trivial to prove.
The primary key currently can be wrapped in a chain
of monotonic functions, so following would work:

toStartOfHour(dt) = toStartOfHour(now()) AND dt = now()

It must be however explicitly stated, if we wanted
to infer that we’d have to know the inverse function,
and prove that the inverse function is monotonic
on given interval. This is not practical as
there is no inverse function that for example undos
rounding, it isn’t strictly monotonic.

There are however functions that don’t transform
output range and preserve monotonicity on the
complete input range, such as rounding or casts
to a same or wider numeric type. This eliminates
the need to find inverse function, as no check for monotonicity over arbitrary interval is needed,
and thus makes this optimisation possible.
2017-07-09 17:13:51 +03:00
Vitaliy Lyudvichenko
7150e9447a Fixed multiIf in case of empty arguments. [#CLICKHOUSE-3119] 2017-07-07 17:42:37 +03:00
Guillaume Tassery
2ec96fe822 Make UUID as a strong type 2017-07-06 16:50:29 +02:00
Guillaume Tassery
cba9815981 Change Uuid to UUID datatype and make UInt128 a generic type 2017-07-04 12:42:53 +02:00
Guillaume Tassery
d6ab06437a Remove mention of UUID type for dictonnary 2017-07-03 18:08:32 +02:00
Alexey Milovidov
5a015a1475 Misc fixes after merge [#CLICKHOUSE-3]. 2017-07-03 17:17:46 +03:00
Alexey Milovidov
a38bf1cbb3 Fixed bad code after merge [#CLICKHOUSE-3]. 2017-07-03 17:16:20 +03:00
Alexey Milovidov
320b1e635b Fixed build after merge [#CLICKHOUSE-3]. 2017-07-03 17:14:44 +03:00
Alexey Milovidov
43daa720a4 Fixed build after merge [#CLICKHOUSE-3]. 2017-07-03 17:09:32 +03:00
Maxim Fridental
e30c9242bc Implement functions findClusterIndex and findClusterValue. 2017-07-03 17:01:21 +03:00
Guillaume Tassery
525851ec68 sync master 2017-06-30 22:21:42 +02:00
Guillaume Tassery
1231952fca Implement UUID type and toUuid function 2017-06-30 22:01:27 +02:00
proller
4db8d09de9 Reorganize includes. part 1 (#921)
* Make libunwind optional. Allow use custom libcctz

* fix

* Fix

* fix

* Update BaseDaemon.cpp

* Update CMakeLists.txt

* Reorganize includes. part 1

* Update dbms_include.cmake

* Reorganize includes. part 2

* Reorganize includes. part 3

* dbms/src/Common/ThreadPool -> libs/libcommon

* Reorganize includes. part 4

* Fix print_include_directories

* Update thread_creation_latency.cpp

* Update StringRef.h
2017-06-23 23:22:35 +03:00
Alexey Zatelepin
87fbfe0950 correct comparisons for strings with null bytes [#CLICKHOUSE-3070] 2017-06-22 23:10:43 +03:00
Alexey Milovidov
6df5d556e5 Changed namespace [#DEVTOOLS-3381]. 2017-06-21 11:35:38 +03:00
Alexey Milovidov
604de2bfeb Better [#DEVTOOLS-3381]. 2017-06-21 04:24:05 +03:00
Георгий Кондратьев
a736ef618a Put ClickHouse variant of CityHash into DB namespace [#DEVTOOLS-3381]
This avoids symbol conflict when linking external applications that use another
variant of CityHash in the global namespace with ClickHouse libraries.
2017-06-20 12:25:16 +03:00
Георгий Кондратьев
47161f8425 Specify all link dependencies [#DEVTOOLS-3381]
Tested with:

export LDFLAGS="-Wl,--no-undefined"
cmake -DUSE_STATIC_LIBRARIES=OFF -DBUILD_SHARED_LIBS=ON
2017-06-20 00:53:12 +03:00
Alexey Milovidov
3ec14e0481 Fixed error [#CLICKHOUSE-4]. 2017-06-14 22:31:05 +03:00
Alexey Milovidov
49e8473456 Fixed error [#CLICKHOUSE-2]. 2017-06-13 08:55:04 +03:00
Alexey Milovidov
8ba0ed9aeb Less dependencies [#CLICKHOUSE-2]. 2017-06-13 08:15:12 +03:00
Alexey Milovidov
a73790f17d Less dependencies [#CLICKHOUSE-2]. 2017-06-13 08:14:24 +03:00
Alexey Milovidov
a782f81f8f Moved common code from Functions; fixed build after merge [#CLICKHOUSE-2]. 2017-06-13 07:45:30 +03:00
Alexey Milovidov
77aa0ed3d2 Fixed build [#CLICKHOUSE-31]. 2017-06-13 07:33:07 +03:00