Commit Graph

73955 Commits

Author SHA1 Message Date
Anton Popov
515cc74530 generalize code in IColumn::updatePermutation 2021-10-01 00:11:54 +03:00
Maksim Kita
42e37f4fad Added test 2021-09-30 21:20:15 +03:00
Kseniia Sumarokova
3e0d4faa1e
Merge pull request #29503 from azat/external-db-log-query
Log queries to external databases (since they may be rewritten)
2021-09-30 21:08:57 +03:00
Kseniia Sumarokova
3457868f3d
Merge pull request #26231 from kssenii/interactive-mode-for-clickhouse-local
clickhouse-local interactive mode, merge clickhouse-client and clickhouse-local code
2021-09-30 19:31:34 +03:00
Maksim Kita
2517f70d75
Merge pull request #29568 from kitaisreal/dict-get-db-name-test-fix
Fixed test with dictGet without database name as column default value
2021-09-30 19:26:09 +03:00
Maksim Kita
d538871d56 ExpressionJIT fix short-circuit with alias 2021-09-30 19:23:15 +03:00
Dmitry Novik
f60d57dd58
Merge pull request #29319 from ClickHouse/fasttest-tsv
Generate test_results.tsv for fasttest
2021-09-30 19:07:27 +03:00
alesapin
950f63a104 Fix commit 2021-09-30 18:59:49 +03:00
alesapin
f31c35de48 Fix nullpointer dereference in AddDefaultDatabaseVisitor 2021-09-30 18:56:55 +03:00
Kseniia Sumarokova
ffc4614f30
Merge pull request #29518 from kssenii/fix-odbc-invalid-cursor
Fix possible odbc invalid cursor state
2021-09-30 18:53:18 +03:00
Alexey Milovidov
551c52c236 Merge remote-tracking branch 'origin/master' into yandex-to-clickhouse-in-configs 2021-09-30 17:45:14 +03:00
Alexey Milovidov
6b2dce7440 Merge branch 'yandex-to-clickhouse-in-configs' of github.com:yandex/ClickHouse into yandex-to-clickhouse-in-configs 2021-09-30 17:44:54 +03:00
mergify[bot]
bfbe49a268
Merge branch 'master' into improvement/fn-traits 2021-09-30 14:26:19 +00:00
alexey-milovidov
3796ccb912
Merge pull request #29540 from myrrc/improvement/monotonicity-aggregate
Making Monotonicity an aggregate to use with designated initializers
2021-09-30 17:26:06 +03:00
Nikolai Kochetov
bc91d7ea60 Fix crash. 2021-09-30 16:48:04 +03:00
Maksim Kita
7bc6b8fd70
Merge pull request #28604 from azat/safer-http-handler
Proper buffer flush while handling HTTP queries (avoids std::terminate)
2021-09-30 16:44:09 +03:00
Maksim Kita
4eabb71348
Merge pull request #29483 from BiteTheDDDDt/dev_doc
[Doc] update zh doc of windowfunnel
2021-09-30 16:33:13 +03:00
Maksim Kita
6077d2e1c7 Fixed test with dictGet without database name as column default value 2021-09-30 16:19:20 +03:00
Maksim Kita
5c5199ef01
Merge pull request #29502 from azat/fix-INSERT-with-metadata-changes
Fix LOGICAL_ERROR for INSERT with concurrent ALTER
2021-09-30 16:11:50 +03:00
Maksim Kita
c2407fee06 Fixed tests 2021-09-30 14:35:24 +03:00
Maksim Kita
87ce29886e Fixed tests 2021-09-30 13:52:07 +03:00
vdimir
4acd8f3147
Do not add extra parentheses for tuple negate unary operator 2021-09-30 13:47:29 +03:00
Maksim Kita
3e0d6a9709
Merge pull request #29531 from kssenii/fix-paths
Fix pathStartsWith
2021-09-30 12:49:52 +03:00
Maksim Kita
c39ec67c16
Merge pull request #29554 from ClickHouse/blinkov-patch-23
[docs] fix build on Mac OS Big Sur
2021-09-30 12:34:48 +03:00
Vladimir C
bc8d925ac5
Merge pull request #29463 from azat/external-db-null 2021-09-30 11:38:04 +03:00
Nikolay Degterinsky
485e19ff84
Merge pull request #28955 from anneji-dev/alterTable
Add default database for alter table
2021-09-30 11:28:47 +03:00
Nikolai Kochetov
a68a86a230
Merge pull request #29539 from FArthur-cmd/fix_test_names
Fix test names
2021-09-30 11:17:49 +03:00
Ivan Blinkov
10e67006dd
[docs] fix build on Mac OS Big Sur 2021-09-30 11:04:15 +03:00
Azat Khuzhin
032bb55a01 Fix null deference for GROUP BY WITH TOTALS HAVING (when the column from HAVING wasn't selected)
Found by UBsan fuzzer [1].

  [1]: https://clickhouse-test-reports.s3.yandex.net/29503/a4f2663b8209e0e75021d8b84f932bc162c81857/fuzzer_ubsan/report.html#fail1
2021-09-30 10:21:29 +03:00
MaxWk
3cbabe2c68 support conversion between date32 and datetime64 2021-09-30 15:09:36 +08:00
kssenii
410b17b4a1 Fix 2021-09-30 06:35:35 +00:00
mergify[bot]
86a0e3e332
Merge branch 'master' into fix-odbc-invalid-cursor 2021-09-30 06:17:49 +00:00
mergify[bot]
775d8baa0c
Merge branch 'master' into fix-paths 2021-09-30 06:17:04 +00:00
凌涛
a13d6b0aea Check all requests 2021-09-30 13:40:48 +08:00
Alexey Boykov
192633cb9b
Merge branch 'ClickHouse:master' into numeric_tuple_functions 2021-09-30 01:37:37 +03:00
kssenii
59cbe8579d Interrupt listener 2021-09-29 22:01:52 +00:00
mergify[bot]
8852f933bc
Merge branch 'master' into yandex-to-clickhouse-in-configs 2021-09-29 21:48:43 +00:00
Nikita Mikhaylov
54ac0801a2
Merge pull request #28669 from bharatnc/ncb/s2-function-docs
Add initial docs for s2 functions
2021-09-30 00:06:34 +03:00
凌涛
bd78af435d update code and add document 2021-09-30 04:51:02 +08:00
Dmitriy
b549f3a398 Add the query
Вставил текст запроса.
2021-09-29 22:55:48 +03:00
kssenii
07b979bda3 Rewrite to processors 2021-09-29 19:17:02 +00:00
Azat Khuzhin
4618636446 Fix LOGICAL_ERROR for INSERT with metadata changes in parallel
In #28582 the problem was introduced due to it obtains new metadata
snapshot and so it may fail when it will check that headers does not
differs, like in [1]:

<details>

    {7b1256b1-09dc-4cc3-93d9-e9f6e26b0b99} <Fatal> : Logical error: 'Block structure mismatch in  function connect between ConvertingTransform and ReplicatedMergeTreeSink stream: different number of columns:
    a UInt8 UInt8(size = 0), b Int16 Int16(size = 0), c Float32 Float32(size = 0), d String String(size = 0), e Array(UInt8) Array(size = 0, UInt64(size = 0), UInt8(size = 0)), f Nullable(UUID) Nullable(size = 0, UUID(size = 0), UInt8(size = 0)), g Tuple(UInt8, UInt16) Tuple(size = 0, UInt8(size = 0), UInt16(size = 0)), h UInt64 UInt64(size = 0)
    a UInt8 UInt8(size = 0), b Int16 Int16(size = 0), c Float32 Float32(size = 0), d String String(size = 0), e Array(UInt8) Array(size = 0, UInt64(size = 0), UInt8(size = 0)), f Nullable(UUID) Nullable(size = 0, UUID(size = 0), UInt8(size = 0)), g Tuple(UInt8, UInt16) Tuple(size = 0, UInt8(size = 0), UInt16(size = 0))'.
    {7b1256b1-09dc-4cc3-93d9-e9f6e26b0b99} <Fatal> : Logical error: 'Block structure mismatch in  function connect between ConvertingTransform and ReplicatedMergeTreeSink stream: different number of columns:
    {} <Fatal> BaseDaemon: ########################################
    {} <Fatal> BaseDaemon: (version 21.11.1.8227, build id: E012027D3A9E94FD61655974C45C15F58215605B) (from thread 2180) (query_id: 7b1256b1-09dc-4cc3-93d9-e9f6e26b0b99) Received signal Aborted (6)
    {} <Fatal> BaseDaemon:
    {} <Fatal> BaseDaemon: Stack trace: 0x7f5661a3b18b 0x7f5661a1a859 0x1333bcb8 0x1333bdc2 0x1d9f04d1 0x1d9eec3c 0x1d9eeeca 0x1f7cc44c 0x1f79b992 0x1e52123f 0x1e522b8e 0x1eb7e27b 0x1eb7be44 0x1f751e26 0x1f75f0e5 0x23ba1179 0x23ba1988 0x23cef8b4 0x23cec39a 0x23ceb17c 0x7f5661c01609 0x7f5661b17293
    {} <Fatal> BaseDaemon: 4. raise @ 0x4618b in /usr/lib/x86_64-linux-gnu/libc-2.31.so
    {} <Fatal> BaseDaemon: 5. abort @ 0x25859 in /usr/lib/x86_64-linux-gnu/libc-2.31.so
    {} <Fatal> BaseDaemon: 6. ./obj-x86_64-linux-gnu/../src/Common/Exception.cpp:53: DB::handle_error_code(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, int, bool, std::__1::vector<void*, std::__1::allocator<void*> > const&) @ 0x1333bcb8 in /usr/bin/clickhouse
    {} <Fatal> BaseDaemon: 7. ./obj-x86_64-linux-gnu/../src/Common/Exception.cpp:60: DB::Exception::Exception(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, int, bool) @ 0x1333bdc2 in /usr/bin/clickhouse
    {} <Fatal> BaseDaemon: 8. ./obj-x86_64-linux-gnu/../src/Core/Block.cpp:32: void DB::onError<void>(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, int) @ 0x1d9f04d1 in /usr/bin/clickhouse
    {} <Fatal> BaseDaemon: 9. ./obj-x86_64-linux-gnu/../src/Core/Block.cpp:86: void DB::checkBlockStructure<void>(DB::Block const&, DB::Block const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, bool) @ 0x1d9eec3c in /usr/bin/clickhouse
    {} <Fatal> BaseDaemon: 10. ./obj-x86_64-linux-gnu/../src/Core/Block.cpp:607: DB::assertCompatibleHeader(DB::Block const&, DB::Block const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&) @ 0x1d9eeeca in /usr/bin/clickhouse
    {} <Fatal> BaseDaemon: 11. ./obj-x86_64-linux-gnu/../src/Processors/Port.cpp:19: DB::connect(DB::OutputPort&, DB::InputPort&) @ 0x1f7cc44c in /usr/bin/clickhouse
    {} <Fatal> BaseDaemon: 12. ./obj-x86_64-linux-gnu/../src/Processors/Chain.cpp:81: DB::Chain::addSource(std::__1::shared_ptr<DB::IProcessor>) @ 0x1f79b992 in /usr/bin/clickhouse
    {} <Fatal> BaseDaemon: 13. ./obj-x86_64-linux-gnu/../src/Interpreters/InterpreterInsertQuery.cpp:222: DB::InterpreterInsertQuery::buildChainImpl(std::__1::shared_ptr<DB::IStorage> const&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&, DB::Block const&, DB::ThreadStatus*, std::__1::atomic<unsigned long>*) @ 0x1e52123f in /usr/bin/clickhouse
    {} <Fatal> BaseDaemon: 14. ./obj-x86_64-linux-gnu/../src/Interpreters/InterpreterInsertQuery.cpp:368: DB::InterpreterInsertQuery::execute() @ 0x1e522b8e in /usr/bin/clickhouse

</details>

  [1]: https://clickhouse-test-reports.s3.yandex.net/29461/d6cd057e2c0c8b04d8a712a7b2a83526507ef512/functional_stateless_tests_(debug).html#fail1

Fixes: #28582 (cc: @KochetovNicolai)
2021-09-29 21:56:59 +03:00
Azat Khuzhin
a4f2663b82 Log queries to external databases (since they may be rewriten)
By rewritten means that some expression from WHERE can be removed, yes
there is external_table_strict_query, but sometimes it is too strict.
2021-09-29 21:56:28 +03:00
Azat Khuzhin
98c311205f Cover IS NULL/IS NOT NULL for MySQL in integration tests 2021-09-29 21:45:09 +03:00
Azat Khuzhin
6ddfbf39c8 Cover IS NULL/IS NOT NULL for external dbs in unit tests 2021-09-29 21:45:09 +03:00
Azat Khuzhin
24f55e29d1 Add support for IS NULL/IS NOT NULL for external dbs 2021-09-29 21:45:09 +03:00
Dmitriy
1d72adfcef Fix by comments
Поправил по комментариям разработчика.
2021-09-29 21:18:41 +03:00
kssenii
2c005db9ad Merge branch 'master' of https://github.com/ClickHouse/ClickHouse into interactive-mode-for-clickhouse-local 2021-09-29 17:45:15 +00:00
Filatenkov Artur
a371a22f16
Update 02010_lc_native.sh 2021-09-29 19:07:40 +03:00
Filatenkov Artur
90c8f50330
Update 02020_alter_table_modify_comment.reference 2021-09-29 19:07:10 +03:00