status
stringclasses 1
value | repo_name
stringclasses 13
values | repo_url
stringclasses 13
values | issue_id
int64 1
104k
| updated_files
stringlengths 11
1.76k
| title
stringlengths 4
369
| body
stringlengths 0
254k
β | issue_url
stringlengths 38
55
| pull_url
stringlengths 38
53
| before_fix_sha
stringlengths 40
40
| after_fix_sha
stringlengths 40
40
| report_datetime
unknown | language
stringclasses 5
values | commit_datetime
unknown |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 23,431 | ["src/Client/Connection.cpp", "src/Client/Connection.h", "src/DataStreams/RemoteQueryExecutor.cpp", "tests/queries/0_stateless/01851_hedged_connections_external_tables.reference", "tests/queries/0_stateless/01851_hedged_connections_external_tables.sql"] | Logical error: Can't initialize pipeline with empty pipe.: While executing Remote (version 21.4.4.30 (official build)) | CREATE TABLE ladnl.dnl_log
(
`event_date` Date,
`date_id` UInt64,
`tm` FixedString(8),
`dt` DateTime DEFAULT toDateTime(concat(toString(event_date), ' ', tm)),
`host_id` UInt32,
`ip` Int32,
`cc` FixedString(2),
`code` UInt16,
`topdir` String,
`file` String,
`size` UInt32,
`flag` String,
`uagent` String,
`ok` UInt8,
`appid` UInt16,
`ver` UInt16 DEFAULT CAST(0, 'UInt16'),
`ltype` UInt16 DEFAULT CAST(0, 'UInt16'),
`keynum` Int16 DEFAULT CAST(0, 'Int16'),
`md5` String,
`serial` String,
`pkid` UInt32,
`pk_member` UInt16,
`pk_product` UInt32,
`cids` String,
`sid` UInt16,
`build` String,
`sku` String,
`iscommercial` UInt8,
`istrial` UInt8,
`isbeta` UInt8,
`iscorporate` UInt8,
`blocked` UInt8,
`expdate` Date,
`pcode` UInt16,
`ssl` UInt8 DEFAULT 0,
`ssl_reuse` UInt8 DEFAULT 0,
`ip_num` String DEFAULT IPv4NumToString(toUInt32(ip)),
`rport` UInt16 DEFAULT CAST(0, 'UInt16'),
`tcp` String,
`base` String,
`comp` String
)
ENGINE = Distributed(dnl2019, 'ladnl', 'dnl_log_local', rand())
SELECT count(),sum(vol) FROM (SELECT count() as cnt,sum(size) as vol FROM ladnl.dnl_log WHERE event_date='2021-04-20' and serial global in (select md5 FROM ladnl.dnl_log WHERE event_date='2021-04-20' AND host_id=191 AND appid=2143 AND keynum>0 group by md5) group by serial HAVING count()=73)
2021.04.21 05:07:53.641943 [ 586494 ] {04d19dd0-692d-4dab-ab46-ac75cdc87eb8} <Error> DynamicQueryHandler: Code: 49, e.displayText() = DB::Exception: Can't initialize pipeline with empty pipe.: While executing Remote, Stack trace (when copying this message, always include the lines below):
0. DB::Exception::Exception(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, int, bool) @ 0x8914f0a in /usr/bin/clickhouse
1. DB::QueryPipeline::init(DB::Pipe) @ 0x101b03f1 in /usr/bin/clickhouse
2. DB::Connection::sendExternalTablesData(std::__1::vector<std::__1::unique_ptr<DB::ExternalTableData, std::__1::default_delete<DB::ExternalTableData> >, std::__1::allocator<std::__1::unique_ptr<DB::ExternalTableData, std::__1::default_delete<DB::ExternalTableData> > > >&) @ 0x1008c5db in /usr/bin/clickhouse
3. DB::HedgedConnections::processNewReplicaState(DB::HedgedConnectionsFactory::State, DB::Connection*) @ 0x100a3f89 in /usr/bin/clickhouse
4. DB::HedgedConnections::getReadyReplicaLocation(std::__1::function<void (int, Poco::Timespan const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&)>) @ 0x100a243f in /usr/bin/clickhouse
5. DB::HedgedConnections::receivePacketUnlocked(std::__1::function<void (int, Poco::Timespan const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&)>) @ 0x100a323e in /usr/bin/clickhouse
6. DB::RemoteQueryExecutorRoutine::operator()(boost::context::fiber&&) const @ 0xf11cb52 in /usr/bin/clickhouse
7. void boost::context::detail::fiber_entry<boost::context::detail::fiber_record<boost::context::fiber, FiberStack&, DB::RemoteQueryExecutorRoutine> >(boost::context::detail::transfer_t) @ 0xf11ca2e in /usr/bin/clickhouse
(version 21.4.4.30 (official build))
| https://github.com/ClickHouse/ClickHouse/issues/23431 | https://github.com/ClickHouse/ClickHouse/pull/23805 | fa1e9de7f7325f5d90aea083fd8c1cc2925a6790 | 7ca42d2ce13e43baddd3ac4aeae214252af0d0f7 | "2021-04-21T11:21:33Z" | c++ | "2021-05-01T05:13:13Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 23,430 | ["tests/integration/helpers/cluster.py", "tests/integration/test_storage_kafka/test.py"] | After the Kafka engine table is deleted, the materialized view cannot consume the Kafka data and submit the offset according to the original construction model. The offset will only be submitted when the Kafka table is queried by select | (you don't have to strictly follow this form)
**Describe the bug**
After the Kafka engine table is deleted, the materialized view cannot consume the Kafka data and submit the offset according to the original construction model. The offset will only be submitted when the Kafka table is queried by select
**Does it reproduce on recent release?**
20.11.3.3
**How to reproduce**
* Clickhouse 20.11.3.3
**Step**
1. Create Kafka Table
```sql
CREATE TABLE IF NOT EXISTS olap_kafka_transform_local ON CLUSTER ck_cluster_1
(
`id` String,
`dt` String,
`cc_level1` String,
`cc_level2` String,
`cc_level3` String,
`app_id` UInt32
) ENGINE = Kafka
SETTINGS
kafka_broker_list = 'xxxxxxx',
kafka_topic_list = 'olap_consume_offline',
kafka_group_name = 'olap_consume_offline_ck_cluster_1',
kafka_format = 'JSONEachRow',
kafka_num_consumers = 6,
kafka_max_block_size = 20000,
kafka_skip_broken_messages = 1048577;;
```
2. delete kafka engine table
```sql
drop table olap_kafka_transform_local ON CLUSTER ck_cluster_1;
```
3. Recreate Kafka table
4. Problems recur
**Expected behavior**
A clear and concise description of what you expected to happen.
**Error message and/or stacktrace**
If applicable, add screenshots to help explain your problem.
**Additional context**
Add any other context about the problem here.
| https://github.com/ClickHouse/ClickHouse/issues/23430 | https://github.com/ClickHouse/ClickHouse/pull/24941 | c0e6aa97a68cb1c4ff67b73070e19aa9b8ad9e4a | b711cede82645667cbb3048d1047a77f187300eb | "2021-04-21T10:21:35Z" | c++ | "2021-06-09T22:13:57Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 23,391 | ["src/Functions/extractTimeZoneFromFunctionArguments.cpp", "src/Functions/now64.cpp", "tests/queries/0_stateless/00921_datetime64_basic.reference", "tests/queries/0_stateless/00921_datetime64_basic.sql"] | `now64` function does not support timezone argument | **Describe the unexpected behaviour**
Neither of these works:
```
now64(3, 'UTC')
now64('UTC', 3)
``` | https://github.com/ClickHouse/ClickHouse/issues/23391 | https://github.com/ClickHouse/ClickHouse/pull/24091 | b0bad25dd38189cbd792e326afd9986c13c6b9e4 | 19fb0d2033ff048a153a38c70dad70051b3a12f9 | "2021-04-20T21:04:12Z" | c++ | "2021-05-14T07:36:40Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 23,376 | ["docs/en/interfaces/cli.md", "docs/ru/interfaces/cli.md", "programs/client/Client.cpp", "programs/local/LocalServer.cpp", "src/Client/ClientBase.cpp", "src/Client/ClientBase.h", "tests/queries/0_stateless/02048_parallel_reading_from_infile.sh", "tests/queries/0_stateless/02751_multiquery_with_argument.reference", "tests/queries/0_stateless/02751_multiquery_with_argument.sh"] | `clickhouse-client --multiquery`: allow to specify queries in the value of the `--multiquery` parameter. | **Use case**
Currently query is accepted in `--query` parameter or in stdin.
There is also `--multiquery` (or `-n`) parameter that is a switch to allow multiple queries.
Example:
```
clickhouse-client --query "SELECT 1"
clickhouse-client --multiquery --query "SELECT 1; SELECT 2;"
```
It will be very intuitive if one will be able to write:
```
clickhouse-client --multiquery "SELECT 1; SELECT 2;"
```
So, the `--multiquery` will act not only as a switch but also as a parameter with value,
if there is no `--query` parameter and the `--multiquery` parameter is presented in its full form (not `-n`). | https://github.com/ClickHouse/ClickHouse/issues/23376 | https://github.com/ClickHouse/ClickHouse/pull/49870 | 3e6314675c6467bc4dd78f659bac862f7e9648f8 | f850a448ecebe6a097d1f4bf711f50a863652bc0 | "2021-04-20T18:40:15Z" | c++ | "2023-05-23T11:48:52Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 23,365 | ["src/DataStreams/ColumnGathererStream.cpp", "src/Processors/Merges/Algorithms/ReplacingSortedAlgorithm.cpp", "tests/queries/0_stateless/00926_adaptive_index_granularity_replacing_merge_tree.reference", "tests/queries/0_stateless/01825_replacing_vertical_merge.reference", "tests/queries/0_stateless/01825_replacing_vertical_merge.sql"] | Vertical merges fails on granule/block size check | **Describe the bug**
Vertical merges seems to be fed with a granule bigger by 1 rows than granularity size, and fails with the following error :
```
2021.04.20 09:59:56.027482 [ 10195 ] {} <Error> database.table_local (813d322c-c51c-47f4-baa7-6c0b90bbab9e): auto DB::StorageReplicatedMergeTree::processQueueEntry(ReplicatedMergeTreeQueue::SelectedEntryPtr)::(anonymous class)::operator()(DB::StorageReplicatedMergeTree::LogEntryPtr &) const: Code: 49, e.displayText() = DB::Exception: Incomplete granules are not allowed while blocks are granules size. Mark number 4665 (rows 4096), rows written in last mark 0, rows to write in last mark from block 1 (from row 4096), total marks currently 4666, Stack trace (when copying this message, always include the lines below):#012#0120. DB::Exception::Exception<unsigned long&, unsigned long, unsigned long&, unsigned long&, unsigned long&, unsigned long>(int, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, unsigned long&, unsigned long&&, unsigned long&, unsigned long&, unsigned long&, unsigned long&&) @ 0xfa5c975 in /usr/bin/clickhouse#0121. DB::MergeTreeDataPartWriterWide::shiftCurrentMark(std::__1::vector<DB::Granule, std::__1::allocator<DB::Granule> > const&) @ 0xfa5c863 in /usr/bin/clickhouse#0122. DB::MergeTreeDataPartWriterWide::write(DB::Block const&, DB::PODArray<unsigned long, 4096ul, Allocator<false, false>, 15ul, 16ul> const*) @ 0xfa5d31f in /usr/bin/clickhouse#0123. DB::MergeTreeDataMergerMutator::mergePartsToTemporaryPart(DB::FutureMergedMutatedPart const&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&, DB::BackgroundProcessListEntry<DB::MergeListElement, DB::MergeInfo>&, std::__1::shared_ptr<DB::RWLockImpl::LockHolderImpl>&, long, DB::Context const&, std::__1::unique_ptr<DB::IReservation, std::__1::default_delete<DB::IReservation> > const&, bool, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) @ 0xfa153c9 in /usr/bin/clickhouse#0124. DB::StorageReplicatedMergeTree::tryExecuteMerge(DB::ReplicatedMergeTreeLogEntry const&) @ 0xf7d6917 in /usr/bin/clickhouse#0125. DB::StorageReplicatedMergeTree::executeLogEntry(DB::ReplicatedMergeTreeLogEntry&) @ 0xf7cb862 in /usr/bin/clickhouse#0126. ? @ 0xf83cd7f in /usr/bin/clickhouse#0127. DB::ReplicatedMergeTreeQueue::processEntry(std::__1::function<std::__1::shared_ptr<zkutil::ZooKeeper> ()>, std::__1::shared_ptr<DB::ReplicatedMergeTreeLogEntry>&, std::__1::function<bool (std::__1::shared_ptr<DB::ReplicatedMergeTreeLogEntry>&)>) @ 0xfb7d0f8 in /usr/bin/clickhouse#0128. DB::StorageReplicatedMergeTree::processQueueEntry(std::__1::shared_ptr<DB::ReplicatedMergeTreeQueue::SelectedEntry>) @ 0xf7f514d in /usr/bin/clickhouse#0129. ? @ 0xf963667 in /usr/bin/clickhouse#01210. ThreadPoolImpl<ThreadFromGlobalPool>::worker(std::__1::__list_iterator<ThreadFromGlobalPool, void*>) @ 0x89916ff in /usr/bin/clickhouse#01211. ThreadFromGlobalPool::ThreadFromGlobalPool<void ThreadPoolImpl<ThreadFromGlobalPool>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()>(void&&, void ThreadPoolImpl<ThreadFromGlobalPool>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()&&...)::'lambda'()::operator()() @ 0x899367f in /usr/bin/clickhouse#01212. ThreadPoolImpl<std::__1::thread>::worker(std::__1::__list_iterator<std::__1::thread, void*>) @ 0x898edef in /usr/bin/clickhouse#01213. ? @ 0x8992733 in /usr/bin/clickhouse#01214. start_thread @ 0x7fa3 in /usr/lib/x86_64-linux-gnu/libpthread-2.28.so#01215. clone @ 0xf94cf in /usr/lib/x86_64-linux-gnu/libc-2.28.so#012 (version 21.3.4.25)
```
The table engine is ReplicatedReplacingMergeTree
with SETTINGS storage_policy = 'jbod_policy_1', index_granularity = 4096, merge_max_block_size = 4096, index_granularity_bytes = 41943040
The error is clearly deterministic, and will fail to merge in a loop.
**Does it reproduce on recent release?**
21.3.4.25
The merge information :
``` elapsed: 32.740309772
progress: 0.17199233946890857
num_parts: 6
source_part_names: ['31_975_975_0','31_976_976_0','31_977_977_0','31_978_978_0','31_979_979_0','31_980_980_0']
result_part_name: 31_975_980_1
source_part_paths: ['/disk13/clickhouse/store/813/813d322c-c51c-47f4-baa7-6c0b90bbab9e/31_975_975_0/','/disk7/clickhouse/store/813/813d322c-c51c-47f4-baa7-6c0b90bbab9e/31_976_976_0/','/disk4/clickhouse/store/813/813d322c-c51c-47f4-baa7-6c0b90bbab9e/31_977_977_0/','/disk5/clickhouse/store/813/813d322c-c51c-47f4-baa7-6c0b90bbab9e/31_978_978_0/','/disk15/clickhouse/store/813/813d322c-c51c-47f4-baa7-6c0b90bbab9e/31_979_979_0/','/disk10/clickhouse/store/813/813d322c-c51c-47f4-baa7-6c0b90bbab9e/31_980_980_0/']
result_part_path: /disk5/clickhouse/store/813/813d322c-c51c-47f4-baa7-6c0b90bbab9e/31_975_980_1/
partition_id: 31
is_mutation: 0
total_size_bytes_compressed: 1286881212
total_size_marks: 4672
bytes_read_uncompressed: 1955818184
rows_read: 8898560
bytes_written_uncompressed: 1947119248
rows_written: 8857600
columns_written: 0
memory_usage: 79808173
thread_id: 9976
merge_type: REGULAR
merge_algorithm: Vertical
``` | https://github.com/ClickHouse/ClickHouse/issues/23365 | https://github.com/ClickHouse/ClickHouse/pull/23459 | ca230224cfa8939680bb05826fa1bc38e4c3648d | 41ed8aab59b41904cce159b71a1b7ef49aa8a435 | "2021-04-20T14:33:57Z" | c++ | "2021-04-24T00:30:44Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 23,305 | ["src/Storages/MergeTree/KeyCondition.cpp", "tests/queries/0_stateless/01540_verbatim_partition_pruning.reference", "tests/queries/0_stateless/01540_verbatim_partition_pruning.sql"] | Partition pruning toYYYYMM partition key. Wrong query result with != | 21.5.1
```sql
create table test(d Date, k Int64, s String)
Engine=MergeTree partition by (toYYYYMM(d),k) order by (d, k)
insert into test values ('2020-01-01', 1, '');
insert into test values ('2020-01-02', 1, '');
SELECT * FROM test WHERE d != '2020-01-01'
0 rows in set. Elapsed: 0.003 sec.
SELECT * FROM test WHERE identity(d) != '2020-01-01';
βββββββββββdββ¬βkββ¬βsββ
β 2020-01-02 β 1 β β
ββββββββββββββ΄ββββ΄ββββ
SELECT * FROM test WHERE toDate(d) != '2020-01-01';
βββββββββββdββ¬βkββ¬βsββ
β 2020-01-02 β 1 β β
ββββββββββββββ΄ββββ΄ββββ
```
| https://github.com/ClickHouse/ClickHouse/issues/23305 | https://github.com/ClickHouse/ClickHouse/pull/23310 | 013555907cb17a7a13f4184c2e0224fb8b4f09cc | 186b1128d013de950a6a98a68f840ef39d11b4ef | "2021-04-19T11:10:42Z" | c++ | "2021-04-27T04:13:18Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 23,292 | ["src/Storages/MergeTree/MergeTreeData.cpp", "src/Storages/MergeTree/MergeTreeData.h", "src/Storages/MergeTree/PartMovesBetweenShardsOrchestrator.cpp", "src/Storages/StorageMergeTree.cpp", "src/Storages/StorageMergeTree.h", "src/Storages/StorageReplicatedMergeTree.cpp", "src/Storages/StorageReplicatedMergeTree.h"] | Replication may stuck due to clearEmptyParts (>=20.12) | Symptoms: all threads in BackgroundScheduledPool busy, lot of tasks in replication queue, none of the tasks is executing.

Related to #16895
Possible workarounds (poor options): increasing the background_schedule_pool_size to huge values, or restart server every time when that happens etc. -
| https://github.com/ClickHouse/ClickHouse/issues/23292 | https://github.com/ClickHouse/ClickHouse/pull/23315 | 4f129d3f93c94d236963ead62fed50269f6f16a5 | c7bd3b8674db4971383779f37ca9084a7cbfe63b | "2021-04-19T06:55:30Z" | c++ | "2021-06-01T10:52:49Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 23,256 | ["src/Storages/System/StorageSystemStackTrace.cpp"] | Thread name in system.stack_trace | https://github.com/ClickHouse/ClickHouse/issues/23256 | https://github.com/ClickHouse/ClickHouse/pull/24124 | 6024477424ca2a7ae29a217d792e6cc029652c89 | 3a98e7f427fcb0bf982763d79008e4c3673cb4cb | "2021-04-18T04:49:11Z" | c++ | "2021-05-18T11:48:49Z" |
|
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 23,236 | ["src/Dictionaries/getDictionaryConfigurationFromAST.cpp", "tests/queries/0_stateless/01821_dictionary_primary_key_wrong_order.reference", "tests/queries/0_stateless/01821_dictionary_primary_key_wrong_order.sql"] | Wrong behavior in dictionaries when key columns are not the first in column order | (you don't have to strictly follow this form)
**Describe the bug**
After upgrade to 21.3 below dictionaries stopped working properly (confirmed on layout hashed, Clickhouse and ODBC source). All other layouts and sources not tested.
**Does it reproduce on recent release?**
Reproduces in 21.3.4.25
**How to reproduce**
Clickhouse source:
```
DROP table If exists default.dicTest;
DROP DICTIONARY if exists default.testWorking;
create table default.dicTest Engine=MergeTree order by tuple() as select cityHash64(number,1) k, cityHash64(number, 2) v from numbers(100) ;
CREATE DICTIONARY default.testWorking ( k UInt64, v UInt64 )
PRIMARY KEY k
SOURCE(CLICKHOUSE(HOST 'localhost' PORT 9000 USER 'default' DB 'default' TABLE 'dicTest' ) )
LIFETIME(MIN 300 MAX 360)
LAYOUT(HASHED());
CREATE DICTIONARY default.testBuggy ( k UInt64, v UInt64 )
PRIMARY KEY v
SOURCE(CLICKHOUSE(HOST 'localhost' PORT 9000 USER 'default' DB 'default' TABLE 'dicTest' ) )
LIFETIME(MIN 300 MAX 360)
LAYOUT(HASHED());
select * from default.testWorking ;
select * from default.testBuggy ; -- returns only one column, cannot query "v" - key column
select v,k from default.testBuggy ;
-- DB::Exception: Missing columns: 'v' while processing query: 'SELECT v, k FROM default.testBuggy', required columns: 'v' 'k', maybe you meant: ['k','k'] (version 21.3.4.25 (official build))
```
ODBC:
```
----TEST_1 ( Key column is in first place )
hostname :) CREATE DICTIONARY test_dictionary_1 (`XID` UInt8, `XNAME` String, `XSURNAME` String) PRIMARY KEY XID SOURCE(ODBC(CONNECTION_STRING 'DSN=MYODBCSRC' TABLE 'V_TEST_TEST' )) LIFETIME(MIN 300 MAX 86400) LAYOUT(HASHED())
CREATE DICTIONARY test_dictionary_1
(
`XID` UInt8,
`XNAME` String,
`XSURNAME` String
)
PRIMARY KEY XID
SOURCE(ODBC(CONNECTION_STRING 'DSN=MYODBCSRC' TABLE 'V_TEST_TEST'))
LIFETIME(MIN 300 MAX 86400)
LAYOUT(HASHED())
Query id: 360d6407-7049-44ff-b1db-946c3e78bdd8
Ok.
0 rows in set. Elapsed: 0.004 sec.
hostname :) select * from test_dictionary_1;
SELECT *
FROM test_dictionary_1
Query id: 1ee658a0-8898-4ac9-bab1-e8c41ba4c102
--- returns data
1 rows in set. Elapsed: 4.580 sec.
tuna-clickhouse :) select version();
SELECT version()
Query id: 8ba03bb1-c3b5-42d8-9396-cc8deb0da61f
Γ’βΕΓ’ββ¬version()Γ’ββ¬Γ’βΒ
Γ’ββ 21.3.4.25 Γ’ββ
Γ’ββΓ’ββ¬Γ’ββ¬Γ’ββ¬Γ’ββ¬Γ’ββ¬Γ’ββ¬Γ’ββ¬Γ’ββ¬Γ’ββ¬Γ’ββ¬Γ’ββ¬Γ’βΛ
1 rows in set. Elapsed: 0.002 sec.
----TEST_2 ( Key column is not in first place )
hostname :) CREATE DICTIONARY test_dictionary_2 (`XNAME` String, `XID` UInt8, `XSURNAME` String) PRIMARY KEY XID SOURCE(ODBC(CONNECTION_STRING 'DSN=MYODBCSRC' TABLE 'V_TEST_TEST_2' )) LIFETIME(MIN 300 MAX 86400) LAYOUT(HASHED())
CREATE DICTIONARY test_dictionary_2
(
`XNAME` String,
`XID` UInt8,
`XSURNAME` String
)
PRIMARY KEY XID
SOURCE(ODBC(CONNECTION_STRING 'DSN=MYODBCSRC' TABLE 'V_TEST_TEST_2'))
LIFETIME(MIN 300 MAX 86400)
LAYOUT(HASHED())
Query id: 64e06917-8040-41e5-8511-539d129e4c00
Ok.
0 rows in set. Elapsed: 0.003 sec.
hostname :) select * from test_dictionary_2 ;
SELECT *
FROM test_dictionary_2
Query id: 02d070cd-ace7-45ec-b85d-bdcb693547d8
0 rows in set. Elapsed: 2.013 sec.
Received exception from server (version 21.3.4):
Code: 86. DB::Exception: Received from localhost:9000.
DB::Exception: Received error from remote server /?connection_string=DSN%3DMYODBCSRC&columns=columns%20format%20version%3A%201%0A3%20columns%3A%0A%60XNAME%60%20UInt64%0A%60XNAME%60%20String%0A%60XSURNAME%60%20String%0A&max_block_size=8192.
HTTP status code: 500 Internal Server Error,
body: Poco::Exception. Code: 1000, e.code() = 0, e.displayText() = Syntax error: Not a valid unsigned integer: textstring,
hostname :) select version();
SELECT version()
Query id: 5c76be4b-9f34-45da-a712-847e8c006a54
Γ’βΕΓ’ββ¬version()Γ’ββ¬Γ’βΒ
Γ’ββ 21.3.4.25 Γ’ββ
Γ’ββΓ’ββ¬Γ’ββ¬Γ’ββ¬Γ’ββ¬Γ’ββ¬Γ’ββ¬Γ’ββ¬Γ’ββ¬Γ’ββ¬Γ’ββ¬Γ’ββ¬Γ’βΛ
1 rows in set. Elapsed: 0.002 sec.
```
**Expected behavior**
Backward compatibility shall not be broken. All querying to dictionaries shall work exactly in the same way as in previous LTS version.
| https://github.com/ClickHouse/ClickHouse/issues/23236 | https://github.com/ClickHouse/ClickHouse/pull/23262 | 6d3df1e02fbf56def5df8be73bac28b3c2561eb2 | 1f6736284331704a2ef5cf488c33bd1b908de330 | "2021-04-17T18:56:17Z" | c++ | "2021-04-18T21:37:52Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 23,227 | ["CMakeLists.txt", "docker/packager/other/fuzzer.sh", "programs/CMakeLists.txt", "programs/local/CMakeLists.txt", "programs/local/LocalServer.cpp", "programs/main.cpp", "src/Functions/CMakeLists.txt", "src/Functions/getFuzzerData.cpp", "src/Functions/getFuzzerData.h", "src/Functions/registerFunctionsMiscellaneous.cpp"] | Add function `getFuzzerData` | **Use case**
Test one ClickHouse SQL function with libFuzzer in a predefined SQL query.
Example:
```
clickhouse-local --query 'SELECT extractTextFromHTML(getFuzzerData())'
```
**Describe the solution you'd like**
If `clickhouse-local` is compiled with libFuzzer, the fuzzer will execute a query in infinite loop, where the `getFuzzerData` function will return different strings in every iteration, using coverage guided fuzzing.
**Additional context**
What's the reason to have this kind of fuzzing?
Although we can provide very high level entry point for libFuzzer, for example, to generate SQL queries as an input. But that fuzzing method is too broad. By using the method described in this task, we can make fuzzing more targeted and ensure fuzzing for specific functions.
Existing functional tests can be used to guide fuzzing (by replacing arbitrary expressions with `getFuzzerData()`). | https://github.com/ClickHouse/ClickHouse/issues/23227 | https://github.com/ClickHouse/ClickHouse/pull/27526 | 6c16348faa59805ebf44b4bdd92675eee5a2ad17 | 514120adfefd8836b8e0c9c6f89e878d5faf883e | "2021-04-17T15:40:31Z" | c++ | "2021-12-07T12:05:16Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 23,183 | ["contrib/libunwind"] | [aarch64] Uncaught exception in clickhouse-client |
i download the ci build output binary
```shell
wget https://clickhouse-builds.s3.yandex.net/0/9110a76d00807baf9dc368cd613512298188269b/clickhouse_special_build_check/clang-11-aarch64_relwithdebuginfo_none_bundled_unsplitted_disable_False_binary/clickhouse
```
and run command:
```shell
root@ubuntu-8658944997-7vjh6:/# ./clickhouse client -h
libc++abi: terminating with uncaught exception of type boost::wrapexcept<boost::program_options::invalid_command_line_syntax>: the required argument for option is missing
Aborted (core dumped)
root@ubuntu-8658944997-7vjh6:/# uname -a
Linux ubuntu-8658944997-7vjh6 4.19.90-17.ky10.aarch64 #1 SMP Sun Jun 28 14:27:40 CST 2020 aarch64 aarch64 aarch64 GNU/Linux
root@ubuntu-8658944997-7vjh6:/# ./clickhouse client --version
ClickHouse client version 21.5.1.6580 (official build).
```
but our old clickhouse version 20.3.18.186 runing correct:
```shell
[root@Malluma ch]# uname -a
Linux Malluma 4.19.90-17.ky10.aarch64 #1 SMP Sun Jun 28 14:27:40 CST 2020 aarch64 aarch64 aarch64 GNU/Linux
[root@Malluma ch]# ./clickhouse-aarch64-20.3.18.186 client --v
Bad arguments: option '--v' is ambiguous and matches '--version', '--version-clean', and '--vertical'
[root@Malluma ch]# ./clickhouse-aarch64-20.3.18.186 client ---version
Bad arguments: unrecognised option '---version'
[root@Malluma ch]# ./clickhouse-aarch64-20.3.18.186 client -h
Bad arguments: the required argument for option '--host' is missing
```
It seems that the new version brings new bugs?
both new and old version running under QEMU is correctly.
| https://github.com/ClickHouse/ClickHouse/issues/23183 | https://github.com/ClickHouse/ClickHouse/pull/25854 | 956b1f588dbf5e406bf61e8a9b4e329d35af8b70 | 011ed015fa49c8e1a37f6f103c28def5e637a23f | "2021-04-16T10:14:58Z" | c++ | "2021-06-30T13:18:59Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 23,163 | ["tests/queries/0_stateless/01915_merge_prewhere_virtual_column_rand_chao_wang.reference", "tests/queries/0_stateless/01915_merge_prewhere_virtual_column_rand_chao_wang.sql"] | Inconsistent query translation with filters on _table and rand() | **Describe the bug**
Sometimes the query translation behaves incorrectly and inconsistently on queries with _table and rand() in Where clause
**Does it reproduce on recent release?**
ClickHouse server version 20.12.4 revision 54442
**How to reproduce*
```
CREATE TABLE abc
(
`f1` String,
`f2` String
)
ENGINE = MergeTree()
ORDER BY f1
```
The query below could result in different results:
```
SELECT f2 FROM merge('default', '^abc$') PREWHERE _table = 'abc' AND f1 = 'a' AND rand()%100 < 20
```
Result 1:
```
Received exception from server (version 20.12.4):
Code: 47. DB::Exception: Received from hostname:1234. DB::Exception: Missing columns: 'f1' while processing query: 'WITH '' AS _table SELECT f2 FROM merge('default', '^abc$') PREWHERE (_table = 'abc') AND (f1 = 'a') AND ((rand() % 100) < 20)', required columns: 'f2' 'f1', source columns: 'f2'.
```
Note that there is a `WITH '' AS _table` added to the beginning of the query
Result 2:
```
Ok.
0 rows in set. Elapsed: 0.009 sec.
```
Meanwhile the following query without the rand() works consistently:
```
SELECT f2 FROM merge('default', '^abc$') PREWHERE (_table = 'abc') AND (f1 = 'a')
```
| https://github.com/ClickHouse/ClickHouse/issues/23163 | https://github.com/ClickHouse/ClickHouse/pull/25390 | c48402d997d0fbf6fc91c13c96857559ec095a6b | d8174cb9fd45f2ad1f5f4af1c0c490c195bdbac6 | "2021-04-15T20:07:47Z" | c++ | "2021-06-17T17:08:35Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 23,125 | ["src/Processors/QueryPlan/Optimizations/limitPushDown.cpp", "tests/queries/0_stateless/02265_limit_push_down_over_window_functions_bug.reference", "tests/queries/0_stateless/02265_limit_push_down_over_window_functions_bug.sql"] | Window function being applied after LIMIT. | Hi. I noticed that when using window functions with a LIMIT clause, the window function appears to be applied to the result _after_ applying the limit. To me this is rather unintuitive and different from the way I am used to it from other applications.
Is this intended behaviour or should I raise an issue for this?
Example (clickhouse version 21.3.5.42):
````
CREATE TABLE test.window_test ENGINE = MergeTree()
PARTITION BY field
ORDER BY field
SETTINGS index_granularity = 8192
AS
SELECT
'a' AS field
UNION ALL
SELECT
'a' AS field
UNION ALL
SELECT
'b' AS field
UNION ALL
SELECT
'b' AS field
;
set allow_experimental_window_functions = 1;
-- Example query with expected output:
SELECT
field,
count() over (partition by field) AS window_count
FROM
test.window_test;
-- Output
--| field | window_count |
--| a | 2 |
--| a | 2 |
--| b | 2 |
--| b | 2 |
-- Query with LIMIT giving unexpected output:
SELECT
field,
count() over (partition by field) AS window_count
FROM
test.window_test
LIMIT 1;
-- Output
--| field | window_count |
--| a | 1 |
-- Expected Output:
--| field | window_count |
--| a | 2 |
````
| https://github.com/ClickHouse/ClickHouse/issues/23125 | https://github.com/ClickHouse/ClickHouse/pull/36075 | d9ce08915a05b6131cb171606a64a68fd2da6b60 | 362fcfd2b8f50edcf4fc4b43c15ac5ff7c2d964f | "2021-04-15T12:00:32Z" | c++ | "2022-04-13T09:57:37Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 23,056 | ["programs/server/Server.cpp"] | TSan: Segfault in `_exit` interceptor (false positive report in CI) | (you don't have to strictly follow this form)
**Describe the bug**
A clear and concise description of what works not as it is supposed to.
- Fatal log
```
2021.04.14 07:10:05.724520 [ 224553 ] {} <Fatal> BaseDaemon: ########################################
2021.04.14 07:10:05.724783 [ 224553 ] {} <Fatal> BaseDaemon: (version 21.5.1.6560, build id: EF319A043F319839CBC8230FD99D7ED96EEBAD64) (from thread 303) (no query) Received signal Segmentation fault (11)
2021.04.14 07:10:05.724973 [ 224553 ] {} <Fatal> BaseDaemon: Address: 0x7f1ea94b5000 Access: read. Attempted access has violated the permissions assigned to the memory area.
2021.04.14 07:10:05.725202 [ 224553 ] {} <Fatal> BaseDaemon: Stack trace: 0x8e566f0 0x8e3060d 0x8e2d454 0x8e34595 0x8df7701 0x8e7f7aa 0x8e7aced 0x1669677c 0x8e6e85f 0x166b2b94 0x8e6d3d7 0x8e6b93a 0x7f323cd1f0b3 0x8dd292e
2021.04.14 07:10:14.624432 [ 224553 ] {} <Fatal> BaseDaemon: 5. __sanitizer::GetMemoryProfile(void (*)(unsigned long, unsigned long, bool, unsigned long*, unsigned long), unsigned long*, unsigned long) @ 0x8e566f0 in /usr/bin/clickhouse
2021.04.14 07:10:23.535715 [ 224553 ] {} <Fatal> BaseDaemon: 6. __sanitizer::SizeClassAllocator64<__tsan::AP64>::PrintStats() @ 0x8e3060d in /usr/bin/clickhouse
2021.04.14 07:10:38.626513 [ 301 ] {} <Fatal> Application: Child process was terminated by signal 11.
```
full log
```
2021.04.14 07:04:16.641337 [ 56282 ] {} <Trace> ExternalDictionariesLoader: Supposed update time for '3cebddf3-0989-4f7b-b9eb-9b8c9de421ff' is 2021-04-14 07:10:41 (backoff, 11 errors)
2021.04.14 07:04:18.019013 [ 56282 ] {} <Error> ExternalDictionariesLoader: Could not update external dictionary '3cebddf3-0989-4f7b-b9eb-9b8c9de421ff', leaving the previous version, next update is scheduled at 2021-04-14 07:10:41: Code: 60, e.displayText() = DB::Exception: Table test.mt doesn't exist, Stack trace (when copying this message, always include the lines below):
2021.04.14 07:04:18.020529 [ 56282 ] {} <Trace> ExternalDictionariesLoader: Next update time for '3cebddf3-0989-4f7b-b9eb-9b8c9de421ff' was set to 2021-04-14 07:10:41
2021.04.14 07:10:00.100645 [ 4908 ] {} <Trace> system.part_log (1ea51428-9e19-4807-8508-501b4a1d864b): Found 2 old parts to remove.
2021.04.14 07:10:00.100978 [ 4908 ] {} <Debug> system.part_log (1ea51428-9e19-4807-8508-501b4a1d864b): Removing part from filesystem 202104_1_470_223
2021.04.14 07:10:00.101903 [ 4908 ] {} <Debug> system.part_log (1ea51428-9e19-4807-8508-501b4a1d864b): Removing part from filesystem 202104_471_471_0
2021.04.14 07:10:00.208260 [ 24273 ] {} <Debug> TCPHandler: Done processing connection.
2021.04.14 07:10:00.396531 [ 359 ] {} <Trace> SystemLog (system.query_log): Flushing system log, 17 entries to flush up to offset 491049
2021.04.14 07:10:00.427204 [ 201932 ] {} <Debug> system.query_thread_log (4a6aab43-9e69-4474-a0a9-b5aaafdb6c70) (MergerMutator): Merge sorted 6776 rows, containing 43 columns (43 merged, 0 gathered) in 1.218106323 sec., 5562.732802594605 rows/sec., 10.25 MiB/sec.
2021.04.14 07:10:00.428587 [ 359 ] {} <Debug> DiskLocal: Reserving 1.00 MiB on disk `default`, having unreserved 7.02 TiB.
2021.04.14 07:10:00.471601 [ 359 ] {} <Trace> system.query_log (42aef80b-c720-47ae-b9e3-0030b1827423): Renaming temporary part tmp_insert_202104_390_390_0 to 202104_392_392_0.
2021.04.14 07:10:00.484381 [ 359 ] {} <Trace> SystemLog (system.query_log): Flushed system log up to offset 491049
2021.04.14 07:10:00.567422 [ 201932 ] {} <Trace> system.query_thread_log (4a6aab43-9e69-4474-a0a9-b5aaafdb6c70): Renaming temporary part tmp_merge_202104_429_457_7 to 202104_429_457_7.
2021.04.14 07:10:00.568406 [ 201932 ] {} <Trace> system.query_thread_log (4a6aab43-9e69-4474-a0a9-b5aaafdb6c70) (MergerMutator): Merged 2 parts: from 202104_429_456_6 to 202104_457_457_0
2021.04.14 07:10:00.568721 [ 201932 ] {} <Debug> MemoryTracker: Peak memory usage: 116.72 MiB.
2021.04.14 07:10:00.782158 [ 365 ] {} <Trace> test_7.replica1: Number of queued merges (0) and part mutations (0) is greater than max_replicated_merges_in_queue (0), so won't select new parts to merge or mutate.
2021.04.14 07:10:00.842210 [ 387 ] {} <Trace> SystemLog (system.metric_log): Flushing system log, 8 entries to flush up to offset 3833
2021.04.14 07:10:01.004959 [ 387 ] {} <Debug> DiskLocal: Reserving 1.00 MiB on disk `default`, having unreserved 7.02 TiB.
2021.04.14 07:10:01.025121 [ 303 ] {} <Information> Application: Closed connections. But 5 remain. Tip: To increase wait time add to config: <shutdown_wait_unfinished>60</shutdown_wait_unfinished>
2021.04.14 07:10:01.025754 [ 303 ] {} <Information> Application: Will shutdown forcefully.
2021.04.14 07:10:01.030775 [ 316 ] {} <Trace> NuKeeperTCPHandler: Received heartbeat for session #2
2021.04.14 07:10:01.174237 [ 387 ] {} <Trace> system.metric_log (4364fc4a-bdb7-4beb-9b14-02a0dd96eb79): Renaming temporary part tmp_insert_202104_516_516_0 to 202104_523_523_0.
2021.04.14 07:10:01.239059 [ 387 ] {} <Trace> SystemLog (system.metric_log): Flushed system log up to offset 3833
2021.04.14 07:10:01.394145 [ 4355 ] {} <Debug> TCPHandler: Done processing connection.
2021.04.14 07:10:02.427399 [ 201262 ] {} <Trace> system.part_log (1ea51428-9e19-4807-8508-501b4a1d864b): Found 6 old parts to remove.
2021.04.14 07:10:02.427708 [ 201262 ] {} <Debug> system.part_log (1ea51428-9e19-4807-8508-501b4a1d864b): Removing part from filesystem 202104_472_472_0
2021.04.14 07:10:02.428384 [ 201262 ] {} <Debug> system.part_log (1ea51428-9e19-4807-8508-501b4a1d864b): Removing part from filesystem 202104_473_473_0
2021.04.14 07:10:02.428838 [ 201262 ] {} <Debug> system.part_log (1ea51428-9e19-4807-8508-501b4a1d864b): Removing part from filesystem 202104_474_474_0
2021.04.14 07:10:02.429240 [ 201262 ] {} <Debug> system.part_log (1ea51428-9e19-4807-8508-501b4a1d864b): Removing part from filesystem 202104_475_475_0
2021.04.14 07:10:02.429642 [ 201262 ] {} <Debug> system.part_log (1ea51428-9e19-4807-8508-501b4a1d864b): Removing part from filesystem 202104_476_476_0
2021.04.14 07:10:02.430061 [ 201262 ] {} <Debug> system.part_log (1ea51428-9e19-4807-8508-501b4a1d864b): Removing part from filesystem 202104_477_477_0
2021.04.14 07:10:02.782129 [ 25928 ] {} <Debug> TCPHandler: Done processing connection.
2021.04.14 07:10:02.810119 [ 1398 ] {} <Debug> TCPHandler: Done processing connection.
2021.04.14 07:10:03.274675 [ 93887 ] {} <Debug> TCPHandler: Done processing connection.
2021.04.14 07:10:04.024373 [ 371 ] {} <Trace> test_7.replica2: Number of queued merges (0) and part mutations (0) is greater than max_replicated_merges_in_queue (0), so won't select new parts to merge or mutate.
2021.04.14 07:10:04.294157 [ 30247 ] {} <Debug> TCPHandler: Done processing connection.
2021.04.14 07:10:05.723037 [ 385 ] {} <Debug> DiskLocal: Reserving 1.00 MiB on disk `default`, having unreserved 7.02 TiB.
2021.04.14 07:10:05.723767 [ 306 ] {} <Trace> BaseDaemon: Received signal 11
2021.04.14 07:10:05.724520 [ 224553 ] {} <Fatal> BaseDaemon: ########################################
2021.04.14 07:10:05.724783 [ 224553 ] {} <Fatal> BaseDaemon: (version 21.5.1.6560, build id: EF319A043F319839CBC8230FD99D7ED96EEBAD64) (from thread 303) (no query) Received signal Segmentation fault (11)
2021.04.14 07:10:05.724973 [ 224553 ] {} <Fatal> BaseDaemon: Address: 0x7f1ea94b5000 Access: read. Attempted access has violated the permissions assigned to the memory area.
2021.04.14 07:10:05.725202 [ 224553 ] {} <Fatal> BaseDaemon: Stack trace: 0x8e566f0 0x8e3060d 0x8e2d454 0x8e34595 0x8df7701 0x8e7f7aa 0x8e7aced 0x1669677c 0x8e6e85f 0x166b2b94 0x8e6d3d7 0x8e6b93a 0x7f323cd1f0b3 0x8dd292e
2021.04.14 07:10:05.734904 [ 385 ] {} <Trace> system.text_log (c2fdd19d-d817-456c-a032-819dcb92328b): Renaming temporary part tmp_insert_202104_448_448_0 to 202104_455_455_0.
2021.04.14 07:10:05.787684 [ 373 ] {} <Trace> test_7.replica1: Number of queued merges (0) and part mutations (0) is greater than max_replicated_merges_in_queue (0), so won't select new parts to merge or mutate.
2021.04.14 07:10:08.269111 [ 1516 ] {} <Trace> system.opentelemetry_span_log (423851b7-41a2-492c-b465-1cefa09988e3): Found 2 old parts to remove.
2021.04.14 07:10:08.269444 [ 1516 ] {} <Debug> system.opentelemetry_span_log (423851b7-41a2-492c-b465-1cefa09988e3): Removing part from filesystem 202104_390_491_24
2021.04.14 07:10:08.270318 [ 1516 ] {} <Debug> system.opentelemetry_span_log (423851b7-41a2-492c-b465-1cefa09988e3): Removing part from filesystem 202104_492_492_0
2021.04.14 07:10:08.739573 [ 387 ] {} <Trace> SystemLog (system.metric_log): Flushing system log, 8 entries to flush up to offset 3841
2021.04.14 07:10:08.918530 [ 387 ] {} <Debug> DiskLocal: Reserving 1.00 MiB on disk `default`, having unreserved 7.02 TiB.
2021.04.14 07:10:09.030316 [ 378 ] {} <Trace> test_7.replica2: Number of queued merges (0) and part mutations (0) is greater than max_replicated_merges_in_queue (0), so won't select new parts to merge or mutate.
2021.04.14 07:10:09.044403 [ 387 ] {} <Trace> system.metric_log (4364fc4a-bdb7-4beb-9b14-02a0dd96eb79): Renaming temporary part tmp_insert_202104_517_517_0 to 202104_524_524_0.
2021.04.14 07:10:09.113149 [ 387 ] {} <Trace> SystemLog (system.metric_log): Flushed system log up to offset 3841
2021.04.14 07:10:10.792801 [ 369 ] {} <Trace> test_7.replica1: Number of queued merges (0) and part mutations (0) is greater than max_replicated_merges_in_queue (0), so won't select new parts to merge or mutate.
2021.04.14 07:10:11.030750 [ 316 ] {} <Trace> NuKeeperTCPHandler: Received heartbeat for session #2
2021.04.14 07:10:11.987102 [ 383 ] {} <Trace> SystemLog (system.asynchronous_metric_log): Flushing system log, 64 entries to flush up to offset 4160
2021.04.14 07:10:11.992093 [ 383 ] {} <Debug> DiskLocal: Reserving 1.00 MiB on disk `default`, having unreserved 7.02 TiB.
2021.04.14 07:10:11.997749 [ 383 ] {} <Trace> system.asynchronous_metric_log (7006fe7a-0040-4c26-88fd-4ffd97af001e): Renaming temporary part tmp_insert_202104_64_64_0 to 202104_65_65_0.
2021.04.14 07:10:11.999450 [ 383 ] {} <Trace> SystemLog (system.asynchronous_metric_log): Flushed system log up to offset 4160
2021.04.14 07:10:12.526535 [ 372 ] {} <Debug> system.query_thread_log (4a6aab43-9e69-4474-a0a9-b5aaafdb6c70) (MergerMutator): Selected 5 parts from 202104_458_458_0 to 202104_462_462_0
2021.04.14 07:10:12.527416 [ 372 ] {} <Debug> DiskLocal: Reserving 1.00 MiB on disk `default`, having unreserved 7.02 TiB.
2021.04.14 07:10:12.528095 [ 201422 ] {} <Debug> system.query_thread_log (4a6aab43-9e69-4474-a0a9-b5aaafdb6c70) (MergerMutator): Merging 5 parts: from 202104_458_458_0 to 202104_462_462_0 into Compact
2021.04.14 07:10:12.529290 [ 201422 ] {} <Debug> system.query_thread_log (4a6aab43-9e69-4474-a0a9-b5aaafdb6c70) (MergerMutator): Selected MergeAlgorithm: Horizontal
2021.04.14 07:10:12.533233 [ 201422 ] {} <Trace> MergeTreeSequentialSource: Reading 2 marks from part 202104_458_458_0, total 18 rows starting from the beginning of the part
2021.04.14 07:10:12.538435 [ 201422 ] {} <Trace> MergeTreeSequentialSource: Reading 2 marks from part 202104_459_459_0, total 22 rows starting from the beginning of the part
2021.04.14 07:10:12.545584 [ 201422 ] {} <Trace> MergeTreeSequentialSource: Reading 2 marks from part 202104_460_460_0, total 18 rows starting from the beginning of the part
2021.04.14 07:10:12.552370 [ 201422 ] {} <Trace> MergeTreeSequentialSource: Reading 2 marks from part 202104_461_461_0, total 37 rows starting from the beginning of the part
2021.04.14 07:10:12.559247 [ 201422 ] {} <Trace> MergeTreeSequentialSource: Reading 2 marks from part 202104_462_462_0, total 25 rows starting from the beginning of the part
2021.04.14 07:10:12.653799 [ 201422 ] {} <Debug> system.query_thread_log (4a6aab43-9e69-4474-a0a9-b5aaafdb6c70) (MergerMutator): Merge sorted 120 rows, containing 43 columns (43 merged, 0 gathered) in 0.125761443 sec., 954.1875247089841 rows/sec., 914.76 KiB/sec.
2021.04.14 07:10:12.673384 [ 201422 ] {} <Trace> system.query_thread_log (4a6aab43-9e69-4474-a0a9-b5aaafdb6c70): Renaming temporary part tmp_merge_202104_458_462_1 to 202104_458_462_1.
2021.04.14 07:10:12.674668 [ 201422 ] {} <Trace> system.query_thread_log (4a6aab43-9e69-4474-a0a9-b5aaafdb6c70) (MergerMutator): Merged 5 parts: from 202104_458_458_0 to 202104_462_462_0
2021.04.14 07:10:12.675071 [ 201422 ] {} <Debug> MemoryTracker: Peak memory usage: 4.05 MiB.
2021.04.14 07:10:13.246862 [ 385 ] {} <Debug> DiskLocal: Reserving 1.00 MiB on disk `default`, having unreserved 7.02 TiB.
2021.04.14 07:10:13.259627 [ 385 ] {} <Trace> system.text_log (c2fdd19d-d817-456c-a032-819dcb92328b): Renaming temporary part tmp_insert_202104_449_449_0 to 202104_456_456_0.
2021.04.14 07:10:14.036771 [ 377 ] {} <Trace> test_7.replica2: Number of queued merges (0) and part mutations (0) is greater than max_replicated_merges_in_queue (0), so won't select new parts to merge or mutate.
2021.04.14 07:10:14.624432 [ 224553 ] {} <Fatal> BaseDaemon: 5. __sanitizer::GetMemoryProfile(void (*)(unsigned long, unsigned long, bool, unsigned long*, unsigned long), unsigned long*, unsigned long) @ 0x8e566f0 in /usr/bin/clickhouse
2021.04.14 07:10:15.798394 [ 376 ] {} <Trace> test_7.replica1: Number of queued merges (0) and part mutations (0) is greater than max_replicated_merges_in_queue (0), so won't select new parts to merge or mutate.
2021.04.14 07:10:16.613678 [ 387 ] {} <Trace> SystemLog (system.metric_log): Flushing system log, 8 entries to flush up to offset 3849
2021.04.14 07:10:16.781949 [ 387 ] {} <Debug> DiskLocal: Reserving 1.00 MiB on disk `default`, having unreserved 7.02 TiB.
2021.04.14 07:10:16.921014 [ 387 ] {} <Trace> system.metric_log (4364fc4a-bdb7-4beb-9b14-02a0dd96eb79): Renaming temporary part tmp_insert_202104_518_518_0 to 202104_525_525_0.
2021.04.14 07:10:16.987284 [ 387 ] {} <Trace> SystemLog (system.metric_log): Flushed system log up to offset 3849
2021.04.14 07:10:17.584590 [ 201504 ] {} <Trace> system.opentelemetry_span_log (423851b7-41a2-492c-b465-1cefa09988e3): Found 2 old parts to remove.
2021.04.14 07:10:17.584900 [ 201504 ] {} <Debug> system.opentelemetry_span_log (423851b7-41a2-492c-b465-1cefa09988e3): Removing part from filesystem 202104_390_492_25
2021.04.14 07:10:17.585820 [ 201504 ] {} <Debug> system.opentelemetry_span_log (423851b7-41a2-492c-b465-1cefa09988e3): Removing part from filesystem 202104_493_493_0
2021.04.14 07:10:17.709963 [ 201337 ] {} <Trace> system.text_log (c2fdd19d-d817-456c-a032-819dcb92328b): Found 7 old parts to remove.
2021.04.14 07:10:17.710284 [ 201337 ] {} <Debug> system.text_log (c2fdd19d-d817-456c-a032-819dcb92328b): Removing part from filesystem 202104_374_399_5
2021.04.14 07:10:17.712138 [ 201337 ] {} <Debug> system.text_log (c2fdd19d-d817-456c-a032-819dcb92328b): Removing part from filesystem 202104_400_400_0
2021.04.14 07:10:17.712589 [ 201337 ] {} <Debug> system.text_log (c2fdd19d-d817-456c-a032-819dcb92328b): Removing part from filesystem 202104_401_401_0
2021.04.14 07:10:17.713029 [ 201337 ] {} <Debug> system.text_log (c2fdd19d-d817-456c-a032-819dcb92328b): Removing part from filesystem 202104_402_402_0
2021.04.14 07:10:17.713601 [ 201337 ] {} <Debug> system.text_log (c2fdd19d-d817-456c-a032-819dcb92328b): Removing part from filesystem 202104_403_403_0
2021.04.14 07:10:17.714126 [ 201337 ] {} <Debug> system.text_log (c2fdd19d-d817-456c-a032-819dcb92328b): Removing part from filesystem 202104_404_404_0
2021.04.14 07:10:17.714589 [ 201337 ] {} <Debug> system.text_log (c2fdd19d-d817-456c-a032-819dcb92328b): Removing part from filesystem 202104_405_405_0
2021.04.14 07:10:19.042862 [ 373 ] {} <Trace> test_7.replica2: Number of queued merges (0) and part mutations (0) is greater than max_replicated_merges_in_queue (0), so won't select new parts to merge or mutate.
2021.04.14 07:10:20.771202 [ 385 ] {} <Debug> DiskLocal: Reserving 1.00 MiB on disk `default`, having unreserved 7.02 TiB.
2021.04.14 07:10:20.779801 [ 385 ] {} <Trace> system.text_log (c2fdd19d-d817-456c-a032-819dcb92328b): Renaming temporary part tmp_insert_202104_450_450_0 to 202104_457_457_0.
2021.04.14 07:10:20.781924 [ 369 ] {} <Debug> system.text_log (c2fdd19d-d817-456c-a032-819dcb92328b) (MergerMutator): Selected 3 parts from 202104_432_452_4 to 202104_454_454_0
2021.04.14 07:10:20.783226 [ 369 ] {} <Debug> DiskLocal: Reserving 1.00 MiB on disk `default`, having unreserved 7.02 TiB.
2021.04.14 07:10:20.784058 [ 3195 ] {} <Debug> system.text_log (c2fdd19d-d817-456c-a032-819dcb92328b) (MergerMutator): Merging 3 parts: from 202104_432_452_4 to 202104_454_454_0 into Compact
2021.04.14 07:10:20.784781 [ 3195 ] {} <Debug> system.text_log (c2fdd19d-d817-456c-a032-819dcb92328b) (MergerMutator): Selected MergeAlgorithm: Horizontal
2021.04.14 07:10:20.786267 [ 3195 ] {} <Trace> MergeTreeSequentialSource: Reading 3 marks from part 202104_432_452_4, total 12791 rows starting from the beginning of the part
2021.04.14 07:10:20.788367 [ 3195 ] {} <Trace> MergeTreeSequentialSource: Reading 2 marks from part 202104_453_453_0, total 4214 rows starting from the beginning of the part
2021.04.14 07:10:20.790326 [ 3195 ] {} <Trace> MergeTreeSequentialSource: Reading 2 marks from part 202104_454_454_0, total 285 rows starting from the beginning of the part
2021.04.14 07:10:20.804216 [ 371 ] {} <Trace> test_7.replica1: Number of queued merges (0) and part mutations (0) is greater than max_replicated_merges_in_queue (0), so won't select new parts to merge or mutate.
2021.04.14 07:10:21.030809 [ 316 ] {} <Trace> NuKeeperTCPHandler: Received heartbeat for session #2
2021.04.14 07:10:21.353239 [ 3195 ] {} <Debug> system.text_log (c2fdd19d-d817-456c-a032-819dcb92328b) (MergerMutator): Merge sorted 17290 rows, containing 13 columns (13 merged, 0 gathered) in 0.569351627 sec., 30367.876686510288 rows/sec., 6.90 MiB/sec.
2021.04.14 07:10:21.362103 [ 3195 ] {} <Trace> system.text_log (c2fdd19d-d817-456c-a032-819dcb92328b): Renaming temporary part tmp_merge_202104_432_454_5 to 202104_432_454_5.
2021.04.14 07:10:21.362869 [ 3195 ] {} <Trace> system.text_log (c2fdd19d-d817-456c-a032-819dcb92328b) (MergerMutator): Merged 3 parts: from 202104_432_452_4 to 202104_454_454_0
2021.04.14 07:10:21.363192 [ 3195 ] {} <Debug> MemoryTracker: Peak memory usage: 12.43 MiB.
2021.04.14 07:10:23.203253 [ 200998 ] {} <Trace> system.metric_log (4364fc4a-bdb7-4beb-9b14-02a0dd96eb79): Found 6 old parts to remove.
2021.04.14 07:10:23.203565 [ 200998 ] {} <Debug> system.metric_log (4364fc4a-bdb7-4beb-9b14-02a0dd96eb79): Removing part from filesystem 202104_1_466_93
2021.04.14 07:10:23.204494 [ 200998 ] {} <Debug> system.metric_log (4364fc4a-bdb7-4beb-9b14-02a0dd96eb79): Removing part from filesystem 202104_467_467_0
2021.04.14 07:10:23.204959 [ 200998 ] {} <Debug> system.metric_log (4364fc4a-bdb7-4beb-9b14-02a0dd96eb79): Removing part from filesystem 202104_468_468_0
2021.04.14 07:10:23.205374 [ 200998 ] {} <Debug> system.metric_log (4364fc4a-bdb7-4beb-9b14-02a0dd96eb79): Removing part from filesystem 202104_469_469_0
2021.04.14 07:10:23.205919 [ 200998 ] {} <Debug> system.metric_log (4364fc4a-bdb7-4beb-9b14-02a0dd96eb79): Removing part from filesystem 202104_470_470_0
2021.04.14 07:10:23.206367 [ 200998 ] {} <Debug> system.metric_log (4364fc4a-bdb7-4beb-9b14-02a0dd96eb79): Removing part from filesystem 202104_471_471_0
2021.04.14 07:10:23.535715 [ 224553 ] {} <Fatal> BaseDaemon: 6. __sanitizer::SizeClassAllocator64<__tsan::AP64>::PrintStats() @ 0x8e3060d in /usr/bin/clickhouse
2021.04.14 07:10:24.048444 [ 376 ] {} <Trace> test_7.replica2: Number of queued merges (0) and part mutations (0) is greater than max_replicated_merges_in_queue (0), so won't select new parts to merge or mutate.
2021.04.14 07:10:24.487829 [ 387 ] {} <Trace> SystemLog (system.metric_log): Flushing system log, 8 entries to flush up to offset 3857
2021.04.14 07:10:24.650806 [ 387 ] {} <Debug> DiskLocal: Reserving 1.00 MiB on disk `default`, having unreserved 7.02 TiB.
2021.04.14 07:10:24.795317 [ 387 ] {} <Trace> system.metric_log (4364fc4a-bdb7-4beb-9b14-02a0dd96eb79): Renaming temporary part tmp_insert_202104_519_519_0 to 202104_526_526_0.
2021.04.14 07:10:24.797754 [ 367 ] {} <Debug> system.metric_log (4364fc4a-bdb7-4beb-9b14-02a0dd96eb79) (MergerMutator): Selected 6 parts from 202104_1_521_104 to 202104_526_526_0
``` | https://github.com/ClickHouse/ClickHouse/issues/23056 | https://github.com/ClickHouse/ClickHouse/pull/23616 | 9d0d1b9d30f06c207fb3b6858028e61bc227e44b | 4fd56ef472ba6eb31e7d32403a2c7374cb8553fc | "2021-04-14T06:37:56Z" | c++ | "2021-04-25T07:33:34Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 23,029 | ["src/Core/Block.cpp", "src/Core/Block.h", "src/Processors/Pipe.cpp", "src/Processors/Port.cpp", "src/Processors/QueryPipeline.cpp", "tests/queries/0_stateless/01822_union_and_constans_error.reference", "tests/queries/0_stateless/01822_union_and_constans_error.sql"] | Logical error: Block structure mismatch in QueryPipeline::unitePipelines stream: different columns |
**Describe the bug**
TLPHaving of Sqlancer test
- log [link](https://clickhouse-test-reports.s3.yandex.net/22706/520f4f39eccfcc16491fbc58d9cb44856deb5f53/sqlancer_test/TLPHaving.err)
```
+ java -jar target/sqlancer-1.1.0.jar --num-threads 10 --timeout-seconds 300 --num-queries 1000 --username default --password '' clickhouse --oracle TLPHaving
+ tee /test_output/TLPHaving.out
java.lang.AssertionError: SELECT MAX(((t0.c0)=(t0.c0))), (MIN(t0.c0)) and ((- (COUNT((t0.c0) OR (t0.c0))))), t0.c0, (- (t0.c0)), MIN(t0.c0) FROM t0 GROUP BY t0.c0 HAVING MAX(((t0.c0)>(''))) UNION ALL SELECT MAX(((t0.c0)==(t0.c0))), (MIN(t0.c0)) and ((- (COUNT((t0.c0) OR (t0.c0))))), t0.c0, (- (t0.c0)), MIN(t0.c0) FROM t0 GROUP BY t0.c0 HAVING (NOT (MAX(((t0.c0)>(''))))) UNION ALL SELECT MAX(((t0.c0)=(t0.c0))), (MIN(t0.c0)) and ((- (COUNT((t0.c0) OR (t0.c0))))), t0.c0, (- (t0.c0)), MIN(t0.c0) FROM t0 GROUP BY t0.c0 HAVING ((MAX(((t0.c0)>('')))) IS NULL) SETTINGS aggregate_functions_null_for_empty=1, enable_optimize_predicate_expression=0;
at sqlancer.common.query.SQLQueryAdapter.checkException(SQLQueryAdapter.java:100)
at sqlancer.common.query.SQLQueryAdapter.executeAndGet(SQLQueryAdapter.java:131)
at sqlancer.ComparatorHelper.getResultSetFirstColumnAsString(ComparatorHelper.java:54)
at sqlancer.clickhouse.oracle.tlp.ClickHouseTLPHavingOracle.check(ClickHouseTLPHavingOracle.java:66)
at sqlancer.ProviderAdapter.generateAndTestDatabase(ProviderAdapter.java:49)
at sqlancer.Main$DBMSExecutor.run(Main.java:323)
at sqlancer.Main$2.run(Main.java:507)
at sqlancer.Main$2.runThread(Main.java:485)
at sqlancer.Main$2.run(Main.java:475)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1130)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:630)
at java.base/java.lang.Thread.run(Thread.java:832)
Caused by: ru.yandex.clickhouse.except.ClickHouseUnknownException: ClickHouse exception, code: 1002, host: localhost, port: 8123; localhost:8123 failed to respond
at ru.yandex.clickhouse.except.ClickHouseExceptionSpecifier.getException(ClickHouseExceptionSpecifier.java:91)
at ru.yandex.clickhouse.except.ClickHouseExceptionSpecifier.specify(ClickHouseExceptionSpecifier.java:55)
at ru.yandex.clickhouse.except.ClickHouseExceptionSpecifier.specify(ClickHouseExceptionSpecifier.java:24)
at ru.yandex.clickhouse.ClickHouseStatementImpl.getInputStream(ClickHouseStatementImpl.java:633)
at ru.yandex.clickhouse.ClickHouseStatementImpl.executeQuery(ClickHouseStatementImpl.java:117)
at ru.yandex.clickhouse.ClickHouseStatementImpl.executeQuery(ClickHouseStatementImpl.java:100)
at ru.yandex.clickhouse.ClickHouseStatementImpl.executeQuery(ClickHouseStatementImpl.java:95)
at ru.yandex.clickhouse.ClickHouseStatementImpl.executeQuery(ClickHouseStatementImpl.java:90)
at sqlancer.common.query.SQLQueryAdapter.executeAndGet(SQLQueryAdapter.java:121)
... 10 more
Caused by: org.apache.http.NoHttpResponseException: localhost:8123 failed to respond
at org.apache.http.impl.conn.DefaultHttpResponseParser.parseHead(DefaultHttpResponseParser.java:141)
at org.apache.http.impl.conn.DefaultHttpResponseParser.parseHead(DefaultHttpResponseParser.java:56)
at org.apache.http.impl.io.AbstractMessageParser.parse(AbstractMessageParser.java:259)
at org.apache.http.impl.DefaultBHttpClientConnection.receiveResponseHeader(DefaultBHttpClientConnection.java:163)
at org.apache.http.impl.conn.CPoolProxy.receiveResponseHeader(CPoolProxy.java:157)
at org.apache.http.protocol.HttpRequestExecutor.doReceiveResponse(HttpRequestExecutor.java:273)
at org.apache.http.protocol.HttpRequestExecutor.execute(HttpRequestExecutor.java:125)
at org.apache.http.impl.execchain.MainClientExec.execute(MainClientExec.java:272)
at org.apache.http.impl.execchain.ProtocolExec.execute(ProtocolExec.java:186)
at org.apache.http.impl.execchain.RetryExec.execute(RetryExec.java:89)
at org.apache.http.impl.client.InternalHttpClient.doExecute(InternalHttpClient.java:185)
at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:83)
at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:108)
at ru.yandex.clickhouse.ClickHouseStatementImpl.getInputStream(ClickHouseStatementImpl.java:614)
... 15 more
``` | https://github.com/ClickHouse/ClickHouse/issues/23029 | https://github.com/ClickHouse/ClickHouse/pull/23359 | b67f40bae112b4b946dd0ba82777108d4cb66409 | 9ec6fd19436cc0a7841be23cf77774f6105c85b3 | "2021-04-13T08:36:56Z" | c++ | "2021-04-21T05:46:21Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 23,002 | ["src/Interpreters/TableJoin.h", "tests/queries/0_stateless/01115_join_with_dictionary.reference", "tests/queries/0_stateless/01115_join_with_dictionary.sql"] | (JOIN with dictionary) HashJoin: container overflow (range check) | **Describe the bug**
https://clickhouse-test-reports.s3.yandex.net/22994/eaa092cae2c633d78c8b5856956df420a8c5096c/fuzzer_asan/report.html#fail1
| https://github.com/ClickHouse/ClickHouse/issues/23002 | https://github.com/ClickHouse/ClickHouse/pull/23312 | 2cfc2c8825008767e1479c8d1e9e7ea8a2c132fc | bcede10919c68f53d551ad0aec3d3d2ec1f0db81 | "2021-04-12T20:37:31Z" | c++ | "2021-04-24T01:40:43Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,959 | ["src/IO/ReadHelpers.h", "tests/queries/0_stateless/02313_negative_datetime64.reference", "tests/queries/0_stateless/02313_negative_datetime64.sql"] | DateTime64 mistreats fractional seconds part of negative timestamp | `toUnixTimestamp64*()` functions treat milli-, micro- and nanoseconds in a wrong way when timestamp is negative, for example:
```sql
SELECT toUnixTimestamp64Milli(toDateTime64('1927-01-01 00:00:00', 0, 'Europe/Zurich'))
ββtoUnixTimestamp64Milli(toDateTime64('1927-01-01 00:00:00', 0, 'Europe/Zurich'))ββ
β -1357002000000 β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
SELECT toUnixTimestamp64Milli(toDateTime64('1927-01-01 00:00:00.123', 3, 'Europe/Zurich'))
ββtoUnixTimestamp64Milli(toDateTime64('1927-01-01 00:00:00.123', 3, 'Europe/Zurich'))ββ
β -1357002000123 β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
```
(In the case above, the first timestamp must be less than the second)
Comparison doesn't work properly either:
```sql
SELECT toDateTime64('1969-12-12 12:12:12.13', 2) > toDateTime64('1969-12-12 12:12:12.12', 2)
ββgreater(toDateTime64('1969-12-12 12:12:12.13', 2), toDateTime64('1969-12-12 12:12:12.12', 2))ββ
β 0 β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
SELECT toDateTime64('1979-12-12 12:12:12.13', 2) > toDateTime64('1979-12-12 12:12:12.12', 2)
ββgreater(toDateTime64('1979-12-12 12:12:12.13', 2), toDateTime64('1979-12-12 12:12:12.12', 2))ββ
β 1 β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
```
ClickHouse version 22.2.2.1 | https://github.com/ClickHouse/ClickHouse/issues/22959 | https://github.com/ClickHouse/ClickHouse/pull/37697 | d1cf7a52cc58a74fc6eabc5d97923156299c6ee9 | 7baa54f92f3f7d39894b5f4fd43ec72c40dad1b8 | "2021-04-10T16:40:35Z" | c++ | "2022-06-15T16:30:42Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,948 | ["docs/en/sql-reference/functions/date-time-functions.md", "docs/ru/sql-reference/functions/date-time-functions.md"] | toYearWeek wrong value | According to [CH docs](https://clickhouse.tech/docs/en/sql-reference/functions/date-time-functions/#toweekdatemode), `toYearWeek` mode `0` has return years range 0 - 53, but instead of returning `*year*00` for the corresponding queries, it returns `*year-1*52`:
```
SELECT toYearWeek(toDateTime64('1930-01-01 00:00:00', 0, 'UTC'))
ββtoYearWeek(toDateTime64('1930-01-01 00:00:00', 0, 'UTC'))ββ
β 192952 β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
SELECT toYearWeek(toDateTime64('1942-01-01 00:00:00', 0, 'UTC'))
ββtoYearWeek(toDateTime64('1942-01-01 00:00:00', 0, 'UTC'))ββ
β 194152 β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
``` | https://github.com/ClickHouse/ClickHouse/issues/22948 | https://github.com/ClickHouse/ClickHouse/pull/52090 | d365fade947599ac72cf788b63172eec4a131a89 | 78994c8a96c5f85d3d7881ba78031f4cfacb3ec5 | "2021-04-10T11:52:39Z" | c++ | "2023-07-15T17:31:19Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,930 | ["docs/en/sql-reference/functions/date-time-functions.md", "docs/ru/sql-reference/functions/date-time-functions.md"] | toWeek returning wrong result for some dates | As I understand from [docs](https://clickhouse.tech/docs/en/sql-reference/functions/date-time-functions/#toweekdatemode), the week number for the last days of year must be counted starting from the beginning of THE SAME year (52 or 53). Either this behavior should be fixed or docs should be made more clear.
```
SELECT toWeek(toDateTime64('1971-12-31 23:59:59', 3, 'UTC'), 9)
ββtoWeek(toDateTime64('1971-12-31 23:59:59', 3, 'UTC'), 9)ββ
β 1 β
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
SELECT toWeek(toDateTime64('1969-12-31 23:59:59', 3, 'UTC'), 9)
ββtoWeek(toDateTime64('1969-12-31 23:59:59', 3, 'UTC'), 9)ββ
β 1 β
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
```
| https://github.com/ClickHouse/ClickHouse/issues/22930 | https://github.com/ClickHouse/ClickHouse/pull/58452 | 6b6f395cc7fd944f345a0ac088a6822ed05bca37 | dfacb111230c173b0e3270a2cfd9e3847f3b93eb | "2021-04-09T11:34:26Z" | c++ | "2024-01-03T23:06:24Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,929 | ["tests/queries/0_stateless/02507_to_unix_timestamp_overflow.reference", "tests/queries/0_stateless/02507_to_unix_timestamp_overflow.sql"] | toUnixTimestamp throws exception when DateTime64 out of normal range | toUnixTimestamp() throws exception when DateTime64 out of normal range:
```
SELECT toUnixTimestamp(toDateTime64('1928-12-31 12:12:12.123', 3, 'UTC'))
Received exception from server (version 21.5.1):
Code: 407. DB::Exception: Received from localhost:9000. DB::Exception: Convert overflow: While processing toUnixTimestamp(toDateTime64('1928-12-31 12:12:12.123', 3, 'UTC')).
```
| https://github.com/ClickHouse/ClickHouse/issues/22929 | https://github.com/ClickHouse/ClickHouse/pull/44341 | 1b21cc018ed7259d7ef25eab86184d203c9d0f56 | 55131f7ae812e55aaf943a65599b4741e0f537c7 | "2021-04-09T10:32:43Z" | c++ | "2022-12-27T11:58:28Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,924 | ["src/Interpreters/QueryAliasesVisitor.cpp", "tests/queries/0_stateless/01813_distributed_scalar_subqueries_alias.reference", "tests/queries/0_stateless/01813_distributed_scalar_subqueries_alias.sql"] | "Not found column in block" in distributed query with subquery | **How to reproduce**
* Which ClickHouse server version to use
latest master/arcadia
* Non-default settings, if any
```sql
SET prefer_localhost_replica=0
```
(With a local stream the query works fine)
* `CREATE TABLE` statements for all tables involved
```sql
create table "t0" (a Int64, b Int64) engine = MergeTree() partition by a order by a;
create table "dist_t0" (a Int64, b Int64) engine = Distributed(test_shard_localhost, default, t0);
```
* Sample data for all these tables
```sql
insert into t0 values (0, 0);
```
* Queries to run that lead to unexpected result
```sql
di.man.yp-c.yandex.net :) SELECT a / (SELECT sum(number) FROM numbers(10)) FROM dist_t0
SELECT a /
(
SELECT sum(number)
FROM numbers(10)
)
FROM dist_t0
Query id: 27b16db2-ad76-403c-8ac1-c03bfb9b0daf
0 rows in set. Elapsed: 0.020 sec.
Received exception from server (version 21.5.1):
Code: 10. DB::Exception: Received from localhost:9000. DB::Exception: Not found column divide(a, _subquery4) in block. There are only columns: divide(a, CAST(45, 'UInt64')): While executing Remote.
```
| https://github.com/ClickHouse/ClickHouse/issues/22924 | https://github.com/ClickHouse/ClickHouse/pull/23191 | 28e79973a2c4f32f1e9a98ca71370abfccbaced5 | 02515ff0a4aec0a68d510241d3b7ea013bc6b8cb | "2021-04-09T09:33:50Z" | c++ | "2021-04-20T21:58:47Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,862 | ["utils/CMakeLists.txt"] | Can't build memcpy-bench with lld and shared libraries | Using a clean tree with current master (dc7a2b7f8853b00ee85872d4c32b1ea421f7651f).
**Operating system**
Archlinux
**Cmake version**
cmake version 3.20.0
**Ninja version**
1.10.2
**Compiler name and version**
clang version 11.1.0 (Using ccache via PATH)
ccache version 4.2
**Full cmake and/or ninja output**
Configuration:
```
CFLAGS="-march=native -mtune=native -O3 -pipe -fno-plt -Wall -Wextra -Wno-unused-parameter -g3 -gdwarf -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer"
CXXFLAGS="-march=native -mtune=native -O3 -pipe -fno-plt -Wall -Wextra -Wno-unused-parameter -g3 -gdwarf -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer"
CC=clang
CXX=clang++
cmake -DCMAKE_C_FLAGS="${CFLAGS} -fuse-ld=lld -Wno-error" -DCMAKE_CXX_FLAGS="${CXXFLAGS} -fuse-ld=lld -Wno-error" -DWERROR=0 -DUSE_STATIC_LIBRARIES=0 -DSPLIT_SHARED_LIBRARIES=1 -DCLICKHOUSE_SPLIT_BINARY=1 ..
```
Ninja (final) call:
```
$ ninja utils/memcpy-bench/memcpy-bench
[...]
ld.lld: error: can't create dynamic relocation R_X86_64_32S against local symbol in readonly segment; recompile object files with -fPIC or pass '-Wl,-z,notext' to allow text relocations in the output
>>> defined in utils/memcpy-bench/CMakeFiles/memcpy-bench.dir/memcpy_jart.S.o
>>> referenced by memcpy_jart.S:47 (../utils/memcpy-bench/memcpy_jart.S:47)
>>> utils/memcpy-bench/CMakeFiles/memcpy-bench.dir/memcpy_jart.S.o:(MemCpy)
ld.lld: error: can't create dynamic relocation R_X86_64_64 against local symbol in readonly segment; recompile object files with -fPIC or pass '-Wl,-z,notext' to allow text relocations in the output
>>> defined in utils/memcpy-bench/CMakeFiles/memcpy-bench.dir/memcpy_jart.S.o
>>> referenced by utils/memcpy-bench/CMakeFiles/memcpy-bench.dir/memcpy_jart.S.o:(.rodata+0x0)
```
As far as I can see, using dynamic libraries enables `CMAKE_POSITION_INDEPENDENT_CODE` so all files are built using `fPIE` but `memcpy_jart.S` contains position dependent calls so the linker can't do anything with it. I've tried adding and removing fPIC and fPIE to this directory but since the assembly code already contains these calls it doesn't make a difference.
I think there are several solutions:
* Dont' build `memcpy-bench` if `dbms` was built with position independent code.
* Regenerate `memcpy_jart.S` with -fPIC so that it doesn't contain position dependent code. I hope the resulting file would work in both situations (with and without pic).
* Generate a `memcpy_jart_pic.S` file and choose dinamically between the 2 assembly files depending on the options. | https://github.com/ClickHouse/ClickHouse/issues/22862 | https://github.com/ClickHouse/ClickHouse/pull/22875 | 8af2352e2729e890f113dd2d51449a7c0fec8381 | 6ce5bead4f51d2254ad265d6199c4952468f5aec | "2021-04-08T16:34:04Z" | c++ | "2021-04-09T06:18:56Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,857 | ["src/Functions/FunctionsConversion.h", "tests/queries/0_stateless/01803_const_nullable_map.reference", "tests/queries/0_stateless/01803_const_nullable_map.sql"] | Experimental data type Map: segfault. | Always reproduced:
```
milovidov-desktop :) create table table_map (a Map(String, String), b String) engine = MergeTree() order by a;
CREATE TABLE table_map
(
`a` Map(String, String),
`b` String
)
ENGINE = MergeTree
ORDER BY a
Query id: 8f8120c1-c165-452a-815f-2bcae3957e2a
Ok.
0 rows in set. Elapsed: 0.002 sec.
milovidov-desktop :) SELECT b FROM table_map WHERE a = map('name', NULL, '', NULL)
SELECT b
FROM table_map
WHERE a = {'name', NULL, '', NULL}
``` | https://github.com/ClickHouse/ClickHouse/issues/22857 | https://github.com/ClickHouse/ClickHouse/pull/22939 | 8b34a54c2d0f58c69e1834b12644a8f7b4d910b9 | 969d9f495bbdffeb5387c905d42b05fe4d68e1ee | "2021-04-08T12:53:02Z" | c++ | "2021-04-10T11:13:58Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,852 | ["src/Functions/formatDateTime.cpp", "src/IO/ReadHelpers.h", "tests/queries/0_stateless/018002_formatDateTime_DateTime64_century.reference", "tests/queries/0_stateless/018002_formatDateTime_DateTime64_century.sql", "tests/queries/0_stateless/018002_toDateTime64_large_values.reference", "tests/queries/0_stateless/018002_toDateTime64_large_values.sql"] | formatDateTime() wrong value when year out of normal range | `formatDateTime(..., '%C')` returns wrong value when date is outwith normal range
```
SELECT formatDateTime(toDateTime64('1935-12-12 12:12:12', 0, 'Europe/Moscow'), '%C')
ββformatDateTime(toDateTime64('1935-12-12 12:12:12', 0, 'Europe/Moscow'), '%C')ββ
β 20 β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
SELECT formatDateTime(toDateTime64('1969-12-12 12:12:12', 0, 'Europe/Moscow'), '%C')
ββformatDateTime(toDateTime64('1969-12-12 12:12:12', 0, 'Europe/Moscow'), '%C')ββ
β 21 β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
SELECT formatDateTime(toDateTime64('2200-12-12 12:12:12', 0, 'Europe/Moscow'), '%C')
ββformatDateTime(toDateTime64('2200-12-12 12:12:12', 0, 'Europe/Moscow'), '%C')ββ
β 20 β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
```
ClickHouse version 21.5.1.6463 (official build). | https://github.com/ClickHouse/ClickHouse/issues/22852 | https://github.com/ClickHouse/ClickHouse/pull/22937 | 7e867a26d793395d7962a95a15b7ea3034784fa1 | ee9aaab4bcf8b7f98b485d2b6f30f1a0c41c3988 | "2021-04-08T11:11:51Z" | c++ | "2021-04-12T22:40:25Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,824 | ["src/Functions/dateDiff.cpp", "tests/queries/0_stateless/018001_dateDiff_DateTime64.reference", "tests/queries/0_stateless/018001_dateDiff_DateTime64.sql"] | dateDiff() not working with DateTime64 | DateDiff() function does not support DateTime64:
```
SELECT dateDiff('second', toDateTime64('1927-01-01 00:00:00', 0, 'UTC'), toDateTime64('1927-01-01 00:00:00', 0, 'UTC'))
0 rows in set. Elapsed: 0.024 sec.
Received exception from server (version 21.5.1):
Code: 44. DB::Exception: Received from localhost:9000. DB::Exception: Illegal column for first argument of function dateDiff, must be Date or DateTime: While processing dateDiff('second', toDateTime64('1927-01-01 00:00:00', 0, 'UTC'), toDateTime64('1927-01-01 00:00:00', 0, 'UTC')).
``` | https://github.com/ClickHouse/ClickHouse/issues/22824 | https://github.com/ClickHouse/ClickHouse/pull/22931 | aa6183af864af3b3b3a77ab250eb36a71041dd73 | b571656fd762f13afca4e5ad51b1c41930828ed7 | "2021-04-07T19:14:57Z" | c++ | "2021-04-11T18:36:24Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,736 | ["src/Interpreters/JoinToSubqueryTransformVisitor.cpp", "tests/queries/0_stateless/01839_join_to_subqueries_rewriter_columns_matcher.reference", "tests/queries/0_stateless/01839_join_to_subqueries_rewriter_columns_matcher.sql"] | Bug in COLUMNS function in query with 3+ joins | **Describe the bug**
columns('regexp') didn't return all columns by regexp where 3+ joins in query
**Does it reproduce on recent release?**
version 21.3.4 revision 54447
**How to reproduce**
in query we have 3 columns 'test' but returned only one:
```
select columns('test') from
(select 1 as id, 'a' as test) a
left join (select 1 as id, 'b' as test) b on b.id = a.id
left join (select 1 as id, 'c' as test) c on c.id = a.id;
Query id: 2fc3ebdf-8ec9-4684-af02-3b87bfe18705
ββtestββ
β c β
ββββββββ
1 rows in set. Elapsed: 0.007 sec.
```
but if we change query:
```
select columns('test'), a.test as t1, b.test as t2, c.test as t3 from
(select 1 as id, 'a' as test) a
left join (select 1 as id, 'b' as test) b on b.id = a.id
left join (select 1 as id, 'c' as test) c on c.id = a.id
Query id: 5bf07e05-ec0e-4017-853d-b7b23b8a6b16
ββ--a.testββ¬β--b.testββ¬βtestββ¬βt1ββ¬βt2ββ¬βt3ββ
β a β b β c β a β b β c β
ββββββββββββ΄βββββββββββ΄βββββββ΄βββββ΄βββββ΄βββββ
1 rows in set. Elapsed: 0.006 sec.
``` | https://github.com/ClickHouse/ClickHouse/issues/22736 | https://github.com/ClickHouse/ClickHouse/pull/23501 | f27002b1be1c1b818fb7cff224e7dc8c414d9332 | 2b822d896da8359c705f84b41428dcd5fad90d79 | "2021-04-07T06:44:38Z" | c++ | "2021-04-22T21:24:53Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,728 | ["src/AggregateFunctions/AggregateFunctionMannWhitney.h", "src/AggregateFunctions/AggregateFunctionRankCorrelation.h", "src/Common/Arena.h", "tests/queries/0_stateless/01802_rank_corr_mann_whitney_over_window.reference", "tests/queries/0_stateless/01802_rank_corr_mann_whitney_over_window.sql"] | Server crash when using mannWhitneyUTest over a window |
**Describe the bug**
Crash in 21.4.1.6378 when using mannWhitneyUTest aggregate function.
**How to reproduce**
```
CREATE TABLE default.empsalary
(
`depname` LowCardinality(String),
`empno` UInt64,
`salary` Int32,
`enroll_date` Date
)
ENGINE = MergeTree
ORDER BY enroll_date
SETTINGS index_granularity = 8192
user-host :) select * from empsalary
SELECT *
FROM empsalary
Query id: 64367fe7-67c3-4495-a68f-04115d549fb0
ββdepnameββββ¬βempnoββ¬βsalaryββ¬βenroll_dateββ
β sales β 1 β 5000 β 2006-10-01 β
β develop β 8 β 6000 β 2006-10-01 β
β personnel β 2 β 3900 β 2006-12-23 β
β develop β 10 β 5200 β 2007-08-01 β
β sales β 3 β 4800 β 2007-08-01 β
β sales β 4 β 4800 β 2007-08-08 β
β develop β 11 β 5200 β 2007-08-15 β
β personnel β 5 β 3500 β 2007-12-10 β
β develop β 7 β 4200 β 2008-01-01 β
β develop β 9 β 4500 β 2008-01-01 β
βββββββββββββ΄ββββββββ΄βββββββββ΄ββββββββββββββ
Apr 06,2021 18:03:22 β₯ Example func='mannWhitneyUTest(salary, 1)'
Checking aggregate funcs over rows frame.
Arguments
func
mannWhitneyUTest(salary, 1)
Apr 06,2021 18:03:22 β₯ When I execute query
SELECT mannWhitneyUTest(salary, 1) OVER (ORDER BY salary ROWS BETWEEN CURRENT ROW AND UNBOUNDED FOLLOWING) AS func
FROM empsalary
Apr 06,2021 18:03:22 β₯ By executing command
echo -e "
SELECT mannWhitneyUTest(salary, 1) OVER (ORDER BY salary ROWS BETWEEN CURRENT ROW AND UNBOUNDED FOLLOWING) AS func
FROM empsalary
FORMAT TabSeparatedWithNames" | clickhouse client -n --allow_experimental_window_functions "1"
2ms [clickhouse1] bash# echo -e "
4ms [clickhouse1] > SELECT mannWhitneyUTest(salary, 1) OVER (ORDER BY salary ROWS BETWEEN CURRENT ROW AND UNBOUNDED FOLLOWING) AS func
5ms [clickhouse1] > FROM empsalary
8ms [clickhouse1] > FORMAT TabSeparatedWithNames" | clickhouse client -n --allow_experimental_window_functions "1"
33ms [clickhouse1] func
138ms [clickhouse1] [clickhouse1] 2021.04.07 01:03:22.548322 [ 356 ] <Fatal> BaseDaemon: ########################################
138ms [clickhouse1] [clickhouse1] 2021.04.07 01:03:22.548442 [ 356 ] <Fatal> BaseDaemon: (version 21.4.1.6378 (official build), build id: E9CD326C4028D7B6036A025796AA94E886A6FD1D) (from thread 41) (query_id: 801a44f1-730d-4605-9465-7c2f1d1b9aa2) Received signal Segmentation fault (11)
138ms [clickhouse1] [clickhouse1] 2021.04.07 01:03:22.548478 [ 356 ] <Fatal> BaseDaemon: Address: 0x10 Access: read. Address not mapped to object.
138ms [clickhouse1] [clickhouse1] 2021.04.07 01:03:22.548512 [ 356 ] <Fatal> BaseDaemon: Stack trace: 0xa3efac2 0xa3f2a79 0x10154c53 0x1015506e 0x1015973f 0xfff2fdd 0xffefc91 0xffedc06 0xfffb072 0x88d56bf 0x88d9153 0x7fbd41866609 0x7fbd4178d293
138ms [clickhouse1] [clickhouse1] 2021.04.07 01:03:22.549119 [ 356 ] <Fatal> BaseDaemon: 1. void DB::PODArrayBase<8ul, 32ul, DB::MixedArenaAllocator<4096ul, Allocator<false, false>, DB::AlignedArenaAllocator<8ul>, 8ul>, 0ul, 0ul>::realloc<DB::Arena*&>(unsigned long, DB::Arena*&) @ 0xa3efac2 in /usr/bin/clickhouse
138ms [clickhouse1] [clickhouse1] 2021.04.07 01:03:22.549165 [ 356 ] <Fatal> BaseDaemon: 2. DB::AggregateFunctionMannWhitney::add(char*, DB::IColumn const**, unsigned long, DB::Arena*) const @ 0xa3f2a79 in /usr/bin/clickhouse
138ms [clickhouse1] [clickhouse1] 2021.04.07 01:03:22.549187 [ 356 ] <Fatal> BaseDaemon: 3. DB::WindowTransform::updateAggregationState() @ 0x10154c53 in /usr/bin/clickhouse
138ms [clickhouse1] [clickhouse1] 2021.04.07 01:03:22.549221 [ 356 ] <Fatal> BaseDaemon: 4. DB::WindowTransform::appendChunk(DB::Chunk&) @ 0x1015506e in /usr/bin/clickhouse
138ms [clickhouse1] [clickhouse1] 2021.04.07 01:03:22.549251 [ 356 ] <Fatal> BaseDaemon: 5. DB::WindowTransform::work() @ 0x1015973f in /usr/bin/clickhouse
138ms [clickhouse1] [clickhouse1] 2021.04.07 01:03:22.549278 [ 356 ] <Fatal> BaseDaemon: 6. ? @ 0xfff2fdd in /usr/bin/clickhouse
138ms [clickhouse1] [clickhouse1] 2021.04.07 01:03:22.549312 [ 356 ] <Fatal> BaseDaemon: 7. DB::PipelineExecutor::executeStepImpl(unsigned long, unsigned long, std::__1::atomic<bool>*) @ 0xffefc91 in /usr/bin/clickhouse
138ms [clickhouse1] [clickhouse1] 2021.04.07 01:03:22.549331 [ 356 ] <Fatal> BaseDaemon: 8. DB::PipelineExecutor::executeImpl(unsigned long) @ 0xffedc06 in /usr/bin/clickhouse
138ms [clickhouse1] [clickhouse1] 2021.04.07 01:03:22.549362 [ 356 ] <Fatal> BaseDaemon: 9. ? @ 0xfffb072 in /usr/bin/clickhouse
138ms [clickhouse1] [clickhouse1] 2021.04.07 01:03:22.549393 [ 356 ] <Fatal> BaseDaemon: 10. ThreadPoolImpl<std::__1::thread>::worker(std::__1::__list_iterator<std::__1::thread, void*>) @ 0x88d56bf in /usr/bin/clickhouse
138ms [clickhouse1] [clickhouse1] 2021.04.07 01:03:22.549422 [ 356 ] <Fatal> BaseDaemon: 11. ? @ 0x88d9153 in /usr/bin/clickhouse
139ms [clickhouse1] [clickhouse1] 2021.04.07 01:03:22.549460 [ 356 ] <Fatal> BaseDaemon: 12. start_thread @ 0x9609 in /usr/lib/x86_64-linux-gnu/libpthread-2.31.so
139ms [clickhouse1] [clickhouse1] 2021.04.07 01:03:22.549486 [ 356 ] <Fatal> BaseDaemon: 13. __clone @ 0x122293 in /usr/lib/x86_64-linux-gnu/libc-2.31.so
139ms [clickhouse1] [clickhouse1] 2021.04.07 01:03:22.639326 [ 356 ] <Fatal> BaseDaemon: Checksum of the binary: F0772B88209F31A15D3ADA1A43619151, integrity check passed.
```
**Expected behavior**
No server crash. | https://github.com/ClickHouse/ClickHouse/issues/22728 | https://github.com/ClickHouse/ClickHouse/pull/22876 | 1c28878f5d2144c5fd59deeb0c1e41ec49068269 | 8af2352e2729e890f113dd2d51449a7c0fec8381 | "2021-04-06T22:09:12Z" | c++ | "2021-04-09T06:17:27Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,727 | ["src/Functions/FunctionsExternalDictionaries.h"] | dictGetOrDefault('dict','col',Null,0.0) returns Null | **Describe the unexpected behaviour**
If Null being passed as dictionary key, dictGetOrDefault returns null instead of default value.
**How to reproduce**
Clickhouse version 21.5, 21.1, 20.8
```
CREATE VIEW dict_null_source AS SELECT 1 as key, 1 as val;
CREATE DICTIONARY dict_null (key UInt64, val UInt32) PRIMARY KEY key SOURCE(CLICKHOUSE(host 'localhost' user 'default' table 'dict_null_source' ))LAYOUT(FLAT)LIFETIME(300)
SELECT dictGetOrDefault('default.dict_null', 'val', CAST(NULL, 'Nullable(UInt64)'), 0) AS val
Query id: 79518a8e-b439-4d08-a0b2-85e4b3ef99eb
βββvalββ
β α΄Ία΅α΄Έα΄Έ β
ββββββββ
```
**Additional context**
```
SELECT dictGetOrDefault('default.dict_null', 'val', CAST(1, 'UInt64'))
Query id: 71ec76a1-fb61-4641-9145-79c6bfffd490
0 rows in set. Elapsed: 0.001 sec.
Received exception from server (version 21.5.1):
Code: 42. DB::Exception: Received from localhost:9000. DB::Exception: Wrong argument count for function dictGetOrDefault: While processing dictGetOrDefault('default.dict_null', 'val', CAST(1, 'UInt64')).
```
Error message in 21.1 was better: `Number of arguments for function dictGetOrDefault doesn't match: passed 3, should be 4:`
| https://github.com/ClickHouse/ClickHouse/issues/22727 | https://github.com/ClickHouse/ClickHouse/pull/22821 | ed367855d5b96e52ce2f23c4c382ac6f97b94465 | b8e239c211a28675eb3f2a09acc28fe9c8848c5d | "2021-04-06T20:20:15Z" | c++ | "2021-04-08T07:41:41Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,679 | ["src/Storages/MergeTree/DataPartsExchange.cpp", "src/Storages/MergeTree/IMergeTreeDataPart.cpp", "src/Storages/MergeTree/IMergeTreeDataPart.h", "src/Storages/MergeTree/MergeTreeData.cpp", "tests/integration/test_s3_zero_copy_replication/configs/config.d/s3.xml", "tests/integration/test_s3_zero_copy_replication/test.py"] | Replicated tables with TTL moves or delete do not work when <allow_s3_zero_copy_replication> is set to 1 | **Describe the bug**
When <allow_s3_zero_copy_replication> is set to 1 in the <merge_tree> configuration, replicated tables with TTL moves or delete are broken. SELECT from replicated tables with TTL moves or delete causes errors.
**Does it reproduce on recent release?**
[The list of releases](https://github.com/ClickHouse/ClickHouse/blob/master/utils/list-versions/version_date.tsv)
* 21.4.1 revision 54447
**How to reproduce**
* Version: 21.4.1 revision 54447
* Storage configuration:
```
<yandex>
<storage_configuration>
<disks>
<external>
<type>s3</type>
<endpoint>[AWS S3 endpoint]</endpoint>
<access_key_id>[access_key_id]</access_key_id>
<secret_access_key>[secret_access_key]</secret_access_key>
</external>
<external_tiered>
<type>s3</type>
<endpoint>[AWS S3 endpoint]</endpoint>
<access_key_id>[access_key_id]</access_key_id>
<secret_access_key>[secret_access_key]</secret_access_key>
</external_tiered>
</disks>
<policies>
<external>
<volumes>
<external>
<disk>external</disk>
</external>
</volumes>
</external>
<tiered>
<volumes>
<default>
<disk>external</disk>
</default>
<external>
<disk>external_tiered</disk>
</external>
</volumes>
</tiered>
</policies>
</storage_configuration>
</yandex>
```
* Merge tree configuration:
```
<yandex>
<merge_tree>
<allow_s3_zero_copy_replication>1</allow_s3_zero_copy_replication>
</merge_tree>
</yandex>
```
* Statements to reproduce error:
Note: either of the two following create statements could be used -- the error occurs with both TTL move and TTL delete.
Create replicated table with TTL move on two instances of ClickHouse:
```
CREATE TABLE zero_copy_replication ( d UInt64, d1 DateTime ) ENGINE = ReplicatedMergeTree('/clickhouse/zero_copy_replication_ttl', '1') ORDER BY d
TTL d1 + interval 2 day to volume 'external'
SETTINGS storage_policy='tiered';
CREATE TABLE zero_copy_replication ( d UInt64, d1 DateTime ) ENGINE = ReplicatedMergeTree('/clickhouse/zero_copy_replication_ttl', '2') ORDER BY d
TTL d1 + interval 2 day to volume 'external'
SETTINGS storage_policy='tiered';
```
Alternate create statement, replicated table with TTL delete on two instances of ClickHouse:
```
CREATE TABLE zero_copy_replication ( d UInt64, d1 DateTime ) ENGINE = ReplicatedMergeTree('/clickhouse/zero_copy_replication_ttl', '1') ORDER BY d
TTL d1 + interval 2 day
SETTINGS storage_policy='tiered';
CREATE TABLE zero_copy_replication ( d UInt64, d1 DateTime ) ENGINE = ReplicatedMergeTree('/clickhouse/zero_copy_replication_ttl', '2') ORDER BY d
TTL d1 + interval 2 day
SETTINGS storage_policy='tiered';
```
Insert data into the table, with some rows before the 2 day TTL, and some rows after the 2 day TTL.
Then, SELECT using a command similar to the following:
```
SELECT COUNT() FROM zero_copy_replication
```
**Expected behavior**
Expect to be able to SELECT from a replicated table with TTL with <allow_s3_zero_copy_replication> set to 1.
**Error message and/or stacktrace**
Error message:
```
Code: 499. DB::Exception: Received from localhost:9000.
DB::Exception: <?xml version="1.0" encoding="UTF-8"?><Error><Code>NoSuchKey</Code>
<Message>The specified key does not exist.</Message>
<Key>data/zero-copy-replication/xqzqytlaumwdavygqraanbwlllelhijs</Key>
<RequestId>0W01GFT6FX2J4VDF</RequestId>
<HostId>FGeqq3GokrJx9qHMxu9TeFgmWrm/2nH0c6xMLTAGxcWXBeZgnapkwOfJixZZN9JXjjjd6Ei6CKY=</HostId>
</Error>: (while reading column d): (while reading from part
/var/lib/clickhouse/disks/external/store/83b/83b6fb95-f932-417a-aaaf-c709d864e7a5/all_2_2_0/
from mark 23 with max_rows_to_read = 8192): While executing MergeTreeReverse.
```
| https://github.com/ClickHouse/ClickHouse/issues/22679 | https://github.com/ClickHouse/ClickHouse/pull/22864 | 1d5522af623c70c4b55baed12989a15075f52610 | 5638c1814097476e924b678105f095facdce8a83 | "2021-04-06T00:04:50Z" | c++ | "2021-05-26T07:28:23Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,672 | ["src/Storages/StorageDistributed.cpp"] | can't use default DB in shard config w/o warnings | The only way to use this feature is to specify an empty database name in Distributed table definition, but then you get a warning:
```
CREATE TABLE `demo_loan_all` (...) ENGINE=Distributed(test_cluster_two_shards_different_databases, '', demo_loan_01568, cityHash64(id));
<Warning> StorageDistributed (demo_loan_all): Name of remote database is empty. Default database will be used implicitly.
``` | https://github.com/ClickHouse/ClickHouse/issues/22672 | https://github.com/ClickHouse/ClickHouse/pull/22990 | da681d990708cd15d9ca1d8603bc2505d0bfae45 | 1525e38a3cf29cd7816f223f98418f878ca52e24 | "2021-04-05T18:25:24Z" | c++ | "2021-04-13T15:58:12Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,671 | ["src/Common/ZooKeeper/TestKeeper.cpp", "tests/queries/0_stateless/01152_cross_replication.reference", "tests/queries/0_stateless/01152_cross_replication.sql", "tests/queries/skip_list.json"] | assertion failure in `ON CLUSTER` query with TestKeeper | ```
2021.04.05 20:41:11.963398 [ 589679 ] {f459c27c-24b9-4ca7-ba41-6da0b34e1162} <Debug> executeQuery: (from [::1]:36122, using production parser) (comment: /home/akuzm/ch2/ch/tests/queries/0_stateless/01568_window_functions_distributed.sql)
CREATE TABLE demo_loan_01568 ON CLUSTER test_cluster_two_shards_different_databases ( `id` Int64 COMMENT 'id', `date_stat` Date COMMENT 'date of stat', `customer_no` String COMMENT 'customer no', `loan_principal` Float64 COMMENT 'loan principal' ) ENGINE=ReplacingMergeTree() ORDER BY id PARTITION BY toYYYYMM(date_stat);
2021.04.05 20:41:11.964234 [ 589679 ] {f459c27c-24b9-4ca7-ba41-6da0b34e1162} <Trace> ContextAccess (default): Access granted: CREATE TABLE ON shard_0.demo_loan_01568
2021.04.05 20:41:11.964328 [ 589679 ] {f459c27c-24b9-4ca7-ba41-6da0b34e1162} <Trace> ContextAccess (default): Access granted: CREATE TABLE ON shard_1.demo_loan_01568
2021.04.05 20:41:11.965306 [ 589730 ] {} <Debug> DDLWorker: Scheduling tasks
2021.04.05 20:41:11.965349 [ 589708 ] {} <Trace> DDLWorker: Too early to clean queue, will do it later.
2021.04.05 20:41:11.965527 [ 589730 ] {} <Debug> DDLWorker: Will schedule 1 tasks starting from query-0000000000
2021.04.05 20:41:11.965596 [ 589730 ] {} <Trace> DDLWorker: Checking task query-0000000000
2021.04.05 20:41:11.966655 [ 589730 ] {} <Warning> DDLWorker: There are two the same ClickHouse instances in task query-0000000000: localhost:9000 and localhost:9000. Will use the first one only.
2021.04.05 20:41:11.966853 [ 589679 ] {f459c27c-24b9-4ca7-ba41-6da0b34e1162} <Debug> executeQuery: Query pipeline:
DDLQueryStatusInputStream
2021.04.05 20:41:12.020599 [ 589730 ] {} <Error> DDLWorker: Cannot parse DDL task query-0000000000: Cannot parse query or obtain cluster info. Will try to send error status: 371
Code: 371, e.displayText() = DB::Exception: For a distributed DDL on circular replicated cluster its table name must be qualified by database name. (version 21.4.1.1)
clickhouse-server: /home/akuzm/ch2/ch/src/Interpreters/DDLWorker.cpp:1011: void DB::DDLWorker::createStatusDirs(const std::string &, const DB::ZooKeeperPtr &): Assertion `Coordination::isHardwareError(code) || code == Coordination::Error::ZNONODE' failed.
2021.04.05 20:41:12.021227 [ 589676 ] {} <Trace> BaseDaemon: Received signal 6
2021.04.05 20:41:12.021622 [ 589955 ] {} <Fatal> BaseDaemon: ########################################
2021.04.05 20:41:12.021737 [ 589955 ] {} <Fatal> BaseDaemon: (version 21.4.1.1, build id: 1D9C4F29D5439E3A) (from thread 589730) (no query) Received signal Aborted (6)
2021.04.05 20:41:12.021796 [ 589955 ] {} <Fatal> BaseDaemon:
2021.04.05 20:41:12.021913 [ 589955 ] {} <Fatal> BaseDaemon: Stack trace: 0x7f9fd341a18b 0x7f9fd33f9859 0x7f9fd33f9729 0x7f9fd340af36 0x7f9fbf8f6ebb 0x7f9fbf8ef6a7 0x7f9fbf8eeff4 0x7f9fbf8f23b0 0x7f9fbf8ec7e7 0x7f9fbf907407 0x7f9fbf90736a 0x7f9fbf907292 0x7f9fbf90717f 0x7f9fbf9070ad 0x7f9fbf90707d 0x7f9fbf907055 0x7f9fbf907030 0x7f9fd5c107b9 0x7f9fd5c10765 0x7f9fd550efa4 0x7f9fd5515bb4 0x7f9fd5515b3d 0x7f9fd5515a95 0x7f9fd5515462 0x7f9fd37ad609 0x7f9fd34f6293
2021.04.05 20:41:12.024448 [ 589955 ] {} <Fatal> BaseDaemon: 4. /build/glibc-eX1tMB/glibc-2.31/signal/../sysdeps/unix/sysv/linux/raise.c:51: raise @ 0x4618b in /usr/lib/debug/lib/x86_64-linux-gnu/libc-2.31.so
2021.04.05 20:41:12.028554 [ 589955 ] {} <Fatal> BaseDaemon: 5. /build/glibc-eX1tMB/glibc-2.31/stdlib/abort.c:81: abort @ 0x25859 in /usr/lib/debug/lib/x86_64-linux-gnu/libc-2.31.so
2021.04.05 20:41:12.035536 [ 589955 ] {} <Fatal> BaseDaemon: 6.1. inlined from /build/glibc-eX1tMB/glibc-2.31/intl/loadmsgcat.c:509: get_sysdep_segment_value
2021.04.05 20:41:12.035619 [ 589955 ] {} <Fatal> BaseDaemon: 6. loadmsgcat.c:970: _nl_load_domain.cold @ 0x25729 in /usr/lib/debug/lib/x86_64-linux-gnu/libc-2.31.so
2021.04.05 20:41:12.080832 [ 589955 ] {} <Fatal> BaseDaemon: 7. ? @ 0x36f36 in /usr/lib/debug/lib/x86_64-linux-gnu/libc-2.31.so
2021.04.05 20:41:12.481819 [ 589955 ] {} <Fatal> BaseDaemon: 8. /home/akuzm/ch2/ch/src/Interpreters/DDLWorker.cpp:1012: DB::DDLWorker::createStatusDirs(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::shared_ptr<zkutil::ZooKeeper> const&) @ 0x1611ebb in /home/akuzm/ch2/build-clang11/src/libclickhouse_interpretersd.so
2021.04.05 20:41:12.501654 [ 589697 ] {} <Trace> SystemLog (system.query_thread_log): Flushing system log, 23 entries to flush
2021.04.05 20:41:12.510299 [ 589697 ] {} <Debug> DiskLocal: Reserving 1.00 MiB on disk `default`, having unreserved 74.42 GiB.
2021.04.05 20:41:12.520028 [ 589697 ] {} <Trace> system.query_thread_log: Renaming temporary part tmp_insert_202104_3_3_0 to 202104_1606_1606_0.
2021.04.05 20:41:12.521328 [ 589697 ] {} <Trace> SystemLog (system.query_thread_log): Flushed system log
2021.04.05 20:41:12.531652 [ 589693 ] {} <Trace> SystemLog (system.query_log): Flushing system log, 25 entries to flush
2021.04.05 20:41:12.547796 [ 589693 ] {} <Debug> DiskLocal: Reserving 1.00 MiB on disk `default`, having unreserved 74.42 GiB.
2021.04.05 20:41:12.561346 [ 589693 ] {} <Trace> system.query_log: Renaming temporary part tmp_insert_202104_3_3_0 to 202104_1653_1653_0.
2021.04.05 20:41:12.564002 [ 589693 ] {} <Trace> SystemLog (system.query_log): Flushed system log
2021.04.05 20:41:12.901806 [ 589955 ] {} <Fatal> BaseDaemon: 9. /home/akuzm/ch2/ch/src/Interpreters/DDLWorker.cpp:250: DB::DDLWorker::initAndCheckTask(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >&, std::__1::shared_ptr<zkutil::ZooKeeper> const&)::$_2::operator()(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&) const @ 0x160a6a7 in /home/akuzm/ch2/build-clang11/src/libclickhouse_interpretersd.so
2021.04.05 20:41:13.162367 [ 589691 ] {} <Debug> DNSResolver: Updating DNS cache
2021.04.05 20:41:13.162884 [ 589691 ] {} <Debug> DNSResolver: Updated DNS cache
2021.04.05 20:41:13.288263 [ 589955 ] {} <Fatal> BaseDaemon: 10. /home/akuzm/ch2/ch/src/Interpreters/DDLWorker.cpp:288: DB::DDLWorker::initAndCheckTask(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >&, std::__1::shared_ptr<zkutil::ZooKeeper> const&) @ 0x1609ff4 in /home/akuzm/ch2/build-clang11/src/libclickhouse_interpretersd.so
2021.04.05 20:41:13.674881 [ 589955 ] {} <Fatal> BaseDaemon: 11. /home/akuzm/ch2/ch/src/Interpreters/DDLWorker.cpp:435: DB::DDLWorker::scheduleTasks(bool) @ 0x160d3b0 in /home/akuzm/ch2/build-clang11/src/libclickhouse_interpretersd.so
2021.04.05 20:41:14.080896 [ 589955 ] {} <Fatal> BaseDaemon: 12. /home/akuzm/ch2/ch/src/Interpreters/DDLWorker.cpp:1117: DB::DDLWorker::runMainThread() @ 0x16077e7 in /home/akuzm/ch2/build-clang11/src/libclickhouse_interpretersd.so
2021.04.05 20:41:14.520270 [ 589955 ] {} <Fatal> BaseDaemon: 13. /home/akuzm/ch2/ch/contrib/libcxx/include/type_traits:3624: decltype(*(std::__1::forward<DB::DDLWorker*&>(fp0)).*fp()) std::__1::__invoke_constexpr<void (DB::DDLWorker::*&)(), DB::DDLWorker*&, void>(void (DB::DDLWorker::*&)(), DB::DDLWorker*&) @ 0x1622407 in /home/akuzm/ch2/build-clang11/src/libclickhouse_interpretersd.so
2021.04.05 20:41:14.951255 [ 589955 ] {} <Fatal> BaseDaemon: 14. /home/akuzm/ch2/ch/contrib/libcxx/include/tuple:1415: decltype(auto) std::__1::__apply_tuple_impl<void (DB::DDLWorker::*&)(), std::__1::tuple<DB::DDLWorker*>&, 0ul>(void (DB::DDLWorker::*&)(), std::__1::tuple<DB::DDLWorker*>&, std::__1::__tuple_indices<0ul>) @ 0x162236a in /home/akuzm/ch2/build-clang11/src/libclickhouse_interpretersd.so
2021.04.05 20:41:15.384774 [ 589955 ] {} <Fatal> BaseDaemon: 15. /home/akuzm/ch2/ch/contrib/libcxx/include/tuple:1424: decltype(auto) std::__1::apply<void (DB::DDLWorker::*&)(), std::__1::tuple<DB::DDLWorker*>&>(void (DB::DDLWorker::*&)(), std::__1::tuple<DB::DDLWorker*>&) @ 0x1622292 in /home/akuzm/ch2/build-clang11/src/libclickhouse_interpretersd.so
2021.04.05 20:41:15.843730 [ 589955 ] {} <Fatal> BaseDaemon: 16. /home/akuzm/ch2/ch/src/Common/ThreadPool.h:178: ThreadFromGlobalPool::ThreadFromGlobalPool<void (DB::DDLWorker::*)(), DB::DDLWorker*>(void (DB::DDLWorker::*&&)(), DB::DDLWorker*&&)::'lambda'()::operator()() @ 0x162217f in /home/akuzm/ch2/build-clang11/src/libclickhouse_interpretersd.so
2021.04.05 20:41:16.296689 [ 589955 ] {} <Fatal> BaseDaemon: 17. /home/akuzm/ch2/ch/contrib/libcxx/include/type_traits:3676: decltype(std::__1::forward<void (DB::DDLWorker::*)()>(fp)(std::__1::forward<DB::DDLWorker*>(fp0))) std::__1::__invoke<ThreadFromGlobalPool::ThreadFromGlobalPool<void (DB::DDLWorker::*)(), DB::DDLWorker*>(void (DB::DDLWorker::*&&)(), DB::DDLWorker*&&)::'lambda'()&>(void (DB::DDLWorker::*&&)(), DB::DDLWorker*&&) @ 0x16220ad in /home/akuzm/ch2/build-clang11/src/libclickhouse_interpretersd.so
2021.04.05 20:41:16.754507 [ 589955 ] {} <Fatal> BaseDaemon: 18. /home/akuzm/ch2/ch/contrib/libcxx/include/__functional_base:349: void std::__1::__invoke_void_return_wrapper<void>::__call<ThreadFromGlobalPool::ThreadFromGlobalPool<void (DB::DDLWorker::*)(), DB::DDLWorker*>(void (DB::DDLWorker::*&&)(), DB::DDLWorker*&&)::'lambda'()&>(void (DB::DDLWorker::*&&)()...) @ 0x162207d in /home/akuzm/ch2/build-clang11/src/libclickhouse_interpretersd.so
2021.04.05 20:41:17.205419 [ 589955 ] {} <Fatal> BaseDaemon: 19. /home/akuzm/ch2/ch/contrib/libcxx/include/functional:1608: std::__1::__function::__default_alloc_func<ThreadFromGlobalPool::ThreadFromGlobalPool<void (DB::DDLWorker::*)(), DB::DDLWorker*>(void (DB::DDLWorker::*&&)(), DB::DDLWorker*&&)::'lambda'(), void ()>::operator()() @ 0x1622055 in /home/akuzm/ch2/build-clang11/src/libclickhouse_interpretersd.so
2021.04.05 20:41:17.660224 [ 589955 ] {} <Fatal> BaseDaemon: 20. /home/akuzm/ch2/ch/contrib/libcxx/include/functional:2089: void std::__1::__function::__policy_invoker<void ()>::__call_impl<std::__1::__function::__default_alloc_func<ThreadFromGlobalPool::ThreadFromGlobalPool<void (DB::DDLWorker::*)(), DB::DDLWorker*>(void (DB::DDLWorker::*&&)(), DB::DDLWorker*&&)::'lambda'(), void ()> >(std::__1::__function::__policy_storage const*) @ 0x1622030 in /home/akuzm/ch2/build-clang11/src/libclickhouse_interpretersd.so
2021.04.05 20:41:18.113033 [ 589955 ] {} <Fatal> BaseDaemon: 21. /home/akuzm/ch2/ch/contrib/libcxx/include/functional:2221: std::__1::__function::__policy_func<void ()>::operator()() const @ 0x10e7b9 in /home/akuzm/ch2/build-clang11/programs/server/libclickhouse-server-libd.so
2021.04.05 20:41:18.519333 [ 589955 ] {} <Fatal> BaseDaemon: 22. /home/akuzm/ch2/ch/contrib/libcxx/include/functional:2560: std::__1::function<void ()>::operator()() const @ 0x10e765 in /home/akuzm/ch2/build-clang11/programs/server/libclickhouse-server-libd.so
2021.04.05 20:41:18.613202 [ 589955 ] {} <Fatal> BaseDaemon: 23. /home/akuzm/ch2/ch/src/Common/ThreadPool.cpp:247: ThreadPoolImpl<std::__1::thread>::worker(std::__1::__list_iterator<std::__1::thread, void*>) @ 0x33afa4 in /home/akuzm/ch2/build-clang11/src/libclickhouse_common_iod.so
2021.04.05 20:41:18.674626 [ 589955 ] {} <Fatal> BaseDaemon: 24. /home/akuzm/ch2/ch/src/Common/ThreadPool.cpp:124: void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()::operator()() const @ 0x341bb4 in /home/akuzm/ch2/build-clang11/src/libclickhouse_common_iod.so
2021.04.05 20:41:18.733711 [ 589955 ] {} <Fatal> BaseDaemon: 25. /home/akuzm/ch2/ch/contrib/libcxx/include/type_traits:3676: decltype(std::__1::forward<void>(fp)(std::__1::forward<void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()>(fp0)...)) std::__1::__invoke<void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()>(void&&, void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()&&...) @ 0x341b3d in /home/akuzm/ch2/build-clang11/src/libclickhouse_common_iod.so
2021.04.05 20:41:18.792485 [ 589955 ] {} <Fatal> BaseDaemon: 26. /home/akuzm/ch2/ch/contrib/libcxx/include/thread:281: void std::__1::__thread_execute<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()>(std::__1::tuple<void, void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()>&, std::__1::__tuple_indices<>) @ 0x341a95 in /home/akuzm/ch2/build-clang11/src/libclickhouse_common_iod.so
2021.04.05 20:41:18.851158 [ 589955 ] {} <Fatal> BaseDaemon: 27. /home/akuzm/ch2/ch/contrib/libcxx/include/thread:291: void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()> >(void*) @ 0x341462 in /home/akuzm/ch2/build-clang11/src/libclickhouse_common_iod.so
2021.04.05 20:41:18.851254 [ 589955 ] {} <Fatal> BaseDaemon: 28. start_thread @ 0x9609 in /lib/x86_64-linux-gnu/libpthread-2.31.so
2021.04.05 20:41:18.851572 [ 589955 ] {} <Fatal> BaseDaemon: 29. /build/glibc-eX1tMB/glibc-2.31/misc/../sysdeps/unix/sysv/linux/x86_64/clone.S:97: clone @ 0x122293 in /usr/lib/debug/lib/x86_64-linux-gnu/libc-2.31.so
2021.04.05 20:41:18.851653 [ 589955 ] {} <Fatal> BaseDaemon: Calculated checksum of the binary: 8F064C5E1A2EABEDFA9A4E91C53B5568. There is no information about the reference checksum.
``` | https://github.com/ClickHouse/ClickHouse/issues/22671 | https://github.com/ClickHouse/ClickHouse/pull/23041 | fd424eceb00e4aa535f2e312c4f1e9957a2cac84 | 021cafff49e4e355c337fa0f858b1e64f33c9c7c | "2021-04-05T17:45:29Z" | c++ | "2021-04-14T20:25:40Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,631 | ["src/Processors/Formats/Impl/TabSeparatedRowInputFormat.cpp", "tests/queries/0_stateless/01801_nullable_low_cardinality_tsv.reference", "tests/queries/0_stateless/01801_nullable_low_cardinality_tsv.sh"] | TSV parser reports the incorrect error. | ```
CREATE TABLE testTSV
(
A Date,
S LowCardinality(Nullable(String)),
X Int32,
S1 LowCardinality(Nullable(String)),
S2 Array(String)
)
ENGINE = Memory;
printf '2020-01-01\t\N\t32\t\N\n'|clickhouse-client -q 'insert into testTSV format TSV'
DB::Exception: Unexpected NULL value of not Nullable type LowCardinality(Nullable(String)) (version 20.12.8.5 (official build))
```
But the real error is a missing column in the input stream, because I passed 4 columns instead of 5
```
printf '2020-01-01\t\N\t32\t\N\t[]\n'|clickhouse-client -q 'insert into testTSV format TSV'
ok
``` | https://github.com/ClickHouse/ClickHouse/issues/22631 | https://github.com/ClickHouse/ClickHouse/pull/22863 | f7edcdf7c847f7d45ceede4a6073400ec2c985b7 | ee9b53a34209ef0284ec87f97f947832da7a7655 | "2021-04-05T00:16:54Z" | c++ | "2021-04-09T06:50:50Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,626 | ["src/Core/DecimalComparison.h", "src/DataTypes/IDataType.h", "src/Functions/FunctionsComparison.h", "tests/queries/0_stateless/00700_decimal_compare.reference", "tests/queries/0_stateless/00700_decimal_compare.sql", "tests/queries/0_stateless/02124_comparison_betwwen_decimal_and_float.reference", "tests/queries/0_stateless/02124_comparison_betwwen_decimal_and_float.sql"] | No operation greater between Decimal(9, 2) and Float64 | **Describe the bug**
It's not possible to compare Decimal and Float values. But actually both of them point to some specific value on real number line, so we can compare and that wouldn't produce any precision loss.
**How to reproduce**
Clickhouse 21.5
```
SELECT toDecimal32('11.00', 2) > 1.
Query id: f2c1cba1-748e-42ea-83ac-e117b542d576
0 rows in set. Elapsed: 0.002 sec.
Received exception from server (version 21.5.1):
Code: 43. DB::Exception: Received from localhost:9000. DB::Exception: No operation greater between Decimal(9, 2) and Float64: While processing toDecimal32('11.00', 2) > 1..
```
Loosely related https://github.com/ClickHouse/ClickHouse/issues/5690 | https://github.com/ClickHouse/ClickHouse/issues/22626 | https://github.com/ClickHouse/ClickHouse/pull/31966 | a8203dd01ea65182daa89d9babfae41a9f5a4919 | 12195b149fd9285e85c5589e7527db9389b97de1 | "2021-04-04T19:02:57Z" | c++ | "2022-01-14T09:56:26Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,621 | ["src/Functions/FunctionBinaryArithmetic.h", "src/Functions/intDiv.cpp", "src/Functions/modulo.cpp", "tests/queries/0_stateless/02015_division_by_nullable.reference", "tests/queries/0_stateless/02015_division_by_nullable.sql"] | Null in decimal datatype, division by zero. | **Describe the bug**
There is a lot of similar reports (https://github.com/ClickHouse/ClickHouse/issues/7509) but they mostly related to https://github.com/ClickHouse/ClickHouse/issues/12587 and If/case statements.
**How to reproduce**
Clickhouse version 21.5
```
SELECT
1 / CAST(NULL, 'Nullable(UInt32)') AS int,
1 / CAST(NULL, 'Nullable(UInt32)') AS float
Query id: 8f68936f-3ff9-4637-bc63-c19fc71a58ed
βββintββ¬βfloatββ
β α΄Ία΅α΄Έα΄Έ β α΄Ία΅α΄Έα΄Έ β
ββββββββ΄ββββββββ
SELECT 1 / CAST(NULL, 'Nullable(Decimal(7, 2))')
Query id: ed010d6a-4924-4af3-a200-701deeb9d2f4
0 rows in set. Elapsed: 0.002 sec.
Received exception from server (version 21.5.1):
Code: 153. DB::Exception: Received from localhost:9000. DB::Exception: Division by zero: While processing 1 / CAST(NULL, 'Nullable(Decimal(7, 2))').
```
| https://github.com/ClickHouse/ClickHouse/issues/22621 | https://github.com/ClickHouse/ClickHouse/pull/28352 | 13b2fdc23b8ea653cd8a9d6b925dbf5248d3c1ed | 4bc14dedfb5df5f66ddc10e867852f5ada461892 | "2021-04-04T18:15:46Z" | c++ | "2021-10-07T11:47:53Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,579 | ["src/Server/TCPHandler.cpp"] | Segfault on 21.3.4.25 | `clickhouse-server.err.log`:
```
2021.04.03 20:00:30.453884 [ 7949 ] {} <Error> ServerErrorHandler: Poco::Exception. Code: 1000, e.code() = 107, e.displayText() = Net Exception: Socket is not connected, Stack trace (when copying this message, always include the lines below):
0. Poco::Net::SocketImpl::error(int, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&) @ 0x11f7dc4e in /usr/bin/clickhouse
1. Poco::Net::SocketImpl::peerAddress() @ 0x11f7fec6 in /usr/bin/clickhouse
2. DB::ReadBufferFromPocoSocket::ReadBufferFromPocoSocket(Poco::Net::Socket&, unsigned long) @ 0xeb536fd in /usr/bin/clickhouse
3. DB::TCPHandler::runImpl() @ 0xf8be39e in /usr/bin/clickhouse
4. DB::TCPHandler::run() @ 0xf8d1529 in /usr/bin/clickhouse
5. Poco::Net::TCPServerConnection::start() @ 0x11f84caf in /usr/bin/clickhouse
6. Poco::Net::TCPServerDispatcher::run() @ 0x11f866c1 in /usr/bin/clickhouse
7. Poco::PooledThread::run() @ 0x120bcde9 in /usr/bin/clickhouse
8. Poco::ThreadImpl::runnableEntry(void*) @ 0x120b8c4a in /usr/bin/clickhouse
9. start_thread @ 0x8fb7 in /usr/lib/x86_64-linux-gnu/libpthread-2.29.so
10. __clone @ 0xfa1af in /usr/lib/x86_64-linux-gnu/libc-2.29.so
(version 21.3.4.25 (official build))
2021.04.03 20:00:30.456028 [ 25948 ] {} <Fatal> BaseDaemon: ########################################
2021.04.03 20:00:30.456058 [ 25948 ] {} <Fatal> BaseDaemon: (version 21.3.4.25 (official build), build id: 23EA76BDD7B9132C8FB55EC397DB8BAFBEB73C2B) (from thread 7949) (no query) Received signal Segmentation fault (11)
2021.04.03 20:00:30.456081 [ 25948 ] {} <Fatal> BaseDaemon: Address: 0x8 Access: read. Address not mapped to object.
2021.04.03 20:00:30.456092 [ 25948 ] {} <Fatal> BaseDaemon: Stack trace: 0xf8baaa9 0xf8be259 0x11f866d6 0x120bcde9 0x120b8c4a 0x7f267dea1fb7 0x7f267ddd31af
2021.04.03 20:00:30.456116 [ 25948 ] {} <Fatal> BaseDaemon: 1. DB::TCPHandler::~TCPHandler() @ 0xf8baaa9 in /usr/bin/clickhouse
2021.04.03 20:00:30.456135 [ 25948 ] {} <Fatal> BaseDaemon: 2. DB::TCPHandler::~TCPHandler() @ 0xf8be259 in /usr/bin/clickhouse
2021.04.03 20:00:30.456147 [ 25948 ] {} <Fatal> BaseDaemon: 3. Poco::Net::TCPServerDispatcher::run() @ 0x11f866d6 in /usr/bin/clickhouse
2021.04.03 20:00:30.456157 [ 25948 ] {} <Fatal> BaseDaemon: 4. Poco::PooledThread::run() @ 0x120bcde9 in /usr/bin/clickhouse
2021.04.03 20:00:30.456166 [ 25948 ] {} <Fatal> BaseDaemon: 5. Poco::ThreadImpl::runnableEntry(void*) @ 0x120b8c4a in /usr/bin/clickhouse
2021.04.03 20:00:30.456184 [ 25948 ] {} <Fatal> BaseDaemon: 6. start_thread @ 0x8fb7 in /usr/lib/x86_64-linux-gnu/libpthread-2.29.so
2021.04.03 20:00:30.456198 [ 25948 ] {} <Fatal> BaseDaemon: 7. __clone @ 0xfa1af in /usr/lib/x86_64-linux-gnu/libc-2.29.so
2021.04.03 20:00:30.513905 [ 9027 ] {} <Error> ServerErrorHandler: Code: 101, e.displayText() = DB::NetException: Unexpected packet from client, Stack trace (when copying this message, always include the lines below):
0. DB::TCPHandler::receiveHello() @ 0xf8c55a2 in /usr/bin/clickhouse
1. DB::TCPHandler::runImpl() @ 0xf8be569 in /usr/bin/clickhouse
2. DB::TCPHandler::run() @ 0xf8d1529 in /usr/bin/clickhouse
3. Poco::Net::TCPServerConnection::start() @ 0x11f84caf in /usr/bin/clickhouse
4. Poco::Net::TCPServerDispatcher::run() @ 0x11f866c1 in /usr/bin/clickhouse
5. Poco::PooledThread::run() @ 0x120bcde9 in /usr/bin/clickhouse
6. Poco::ThreadImpl::runnableEntry(void*) @ 0x120b8c4a in /usr/bin/clickhouse
7. start_thread @ 0x8fb7 in /usr/lib/x86_64-linux-gnu/libpthread-2.29.so
8. __clone @ 0xfa1af in /usr/lib/x86_64-linux-gnu/libc-2.29.so
(version 21.3.4.25 (official build))
2021.04.03 20:00:30.641530 [ 9027 ] {} <Error> ServerErrorHandler: Code: 101, e.displayText() = DB::NetException: Unexpected packet from client, Stack trace (when copying this message, always include the lines below):
0. DB::TCPHandler::receiveHello() @ 0xf8c55a2 in /usr/bin/clickhouse
1. DB::TCPHandler::runImpl() @ 0xf8be569 in /usr/bin/clickhouse
2. DB::TCPHandler::run() @ 0xf8d1529 in /usr/bin/clickhouse
3. Poco::Net::TCPServerConnection::start() @ 0x11f84caf in /usr/bin/clickhouse
4. Poco::Net::TCPServerDispatcher::run() @ 0x11f866c1 in /usr/bin/clickhouse
5. Poco::PooledThread::run() @ 0x120bcde9 in /usr/bin/clickhouse
6. Poco::ThreadImpl::runnableEntry(void*) @ 0x120b8c4a in /usr/bin/clickhouse
7. start_thread @ 0x8fb7 in /usr/lib/x86_64-linux-gnu/libpthread-2.29.so
8. __clone @ 0xfa1af in /usr/lib/x86_64-linux-gnu/libc-2.29.so
(version 21.3.4.25 (official build))
2021.04.03 20:00:31.130743 [ 25948 ] {} <Fatal> BaseDaemon: Checksum of the binary: 2CFBBE6A99CCD7B1089118797E40A0C1, integrity check passed.
2021.04.03 20:00:50.479809 [ 7875 ] {} <Fatal> Application: Child process was terminated by signal 11.
```
`clickhouse-server.log`:
```
2021.04.03 20:00:30.451303 [ 7949 ] {} <Trace> TCPHandlerFactory: TCP Request. Address: [::ffff:94.232.41.116]:56733
2021.04.03 20:00:30.453884 [ 7949 ] {} <Error> ServerErrorHandler: Poco::Exception. Code: 1000, e.code() = 107, e.displayText() = Net Exception: Socket is not connected, Stack trace (when copying this message, always include the lines below):
0. Poco::Net::SocketImpl::error(int, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&) @ 0x11f7dc4e in /usr/bin/clickhouse
1. Poco::Net::SocketImpl::peerAddress() @ 0x11f7fec6 in /usr/bin/clickhouse
2. DB::ReadBufferFromPocoSocket::ReadBufferFromPocoSocket(Poco::Net::Socket&, unsigned long) @ 0xeb536fd in /usr/bin/clickhouse
3. DB::TCPHandler::runImpl() @ 0xf8be39e in /usr/bin/clickhouse
4. DB::TCPHandler::run() @ 0xf8d1529 in /usr/bin/clickhouse
5. Poco::Net::TCPServerConnection::start() @ 0x11f84caf in /usr/bin/clickhouse
6. Poco::Net::TCPServerDispatcher::run() @ 0x11f866c1 in /usr/bin/clickhouse
7. Poco::PooledThread::run() @ 0x120bcde9 in /usr/bin/clickhouse
8. Poco::ThreadImpl::runnableEntry(void*) @ 0x120b8c4a in /usr/bin/clickhouse
9. start_thread @ 0x8fb7 in /usr/lib/x86_64-linux-gnu/libpthread-2.29.so
10. __clone @ 0xfa1af in /usr/lib/x86_64-linux-gnu/libc-2.29.so
(version 21.3.4.25 (official build))
2021.04.03 20:00:30.454286 [ 7877 ] {} <Trace> BaseDaemon: Received signal 11
2021.04.03 20:00:30.456028 [ 25948 ] {} <Fatal> BaseDaemon: ########################################
2021.04.03 20:00:30.456058 [ 25948 ] {} <Fatal> BaseDaemon: (version 21.3.4.25 (official build), build id: 23EA76BDD7B9132C8FB55EC397DB8BAFBEB73C2B) (from thread 7949) (no query) Received signal Segmentation fault (11)
2021.04.03 20:00:30.456081 [ 25948 ] {} <Fatal> BaseDaemon: Address: 0x8 Access: read. Address not mapped to object.
2021.04.03 20:00:30.456092 [ 25948 ] {} <Fatal> BaseDaemon: Stack trace: 0xf8baaa9 0xf8be259 0x11f866d6 0x120bcde9 0x120b8c4a 0x7f267dea1fb7 0x7f267ddd31af
2021.04.03 20:00:30.456116 [ 25948 ] {} <Fatal> BaseDaemon: 1. DB::TCPHandler::~TCPHandler() @ 0xf8baaa9 in /usr/bin/clickhouse
2021.04.03 20:00:30.456135 [ 25948 ] {} <Fatal> BaseDaemon: 2. DB::TCPHandler::~TCPHandler() @ 0xf8be259 in /usr/bin/clickhouse
2021.04.03 20:00:30.456147 [ 25948 ] {} <Fatal> BaseDaemon: 3. Poco::Net::TCPServerDispatcher::run() @ 0x11f866d6 in /usr/bin/clickhouse
2021.04.03 20:00:30.456157 [ 25948 ] {} <Fatal> BaseDaemon: 4. Poco::PooledThread::run() @ 0x120bcde9 in /usr/bin/clickhouse
2021.04.03 20:00:30.456166 [ 25948 ] {} <Fatal> BaseDaemon: 5. Poco::ThreadImpl::runnableEntry(void*) @ 0x120b8c4a in /usr/bin/clickhouse
2021.04.03 20:00:30.456184 [ 25948 ] {} <Fatal> BaseDaemon: 6. start_thread @ 0x8fb7 in /usr/lib/x86_64-linux-gnu/libpthread-2.29.so
2021.04.03 20:00:30.456198 [ 25948 ] {} <Fatal> BaseDaemon: 7. __clone @ 0xfa1af in /usr/lib/x86_64-linux-gnu/libc-2.29.so
2021.04.03 20:00:30.511549 [ 7885 ] {} <Trace> default.players_performance: Found 2 old parts to remove.
2021.04.03 20:00:30.511568 [ 7885 ] {} <Debug> default.players_performance: Removing part from filesystem 202104_31615436_31622799_6845
2021.04.03 20:00:30.511901 [ 7885 ] {} <Debug> default.players_performance: Removing part from filesystem 202104_31622800_31622800_0
2021.04.03 20:00:30.513751 [ 9027 ] {} <Trace> TCPHandlerFactory: TCP Request. Address: [::ffff:94.232.41.116]:56952
2021.04.03 20:00:30.513905 [ 9027 ] {} <Error> ServerErrorHandler: Code: 101, e.displayText() = DB::NetException: Unexpected packet from client, Stack trace (when copying this message, always include the lines below):
0. DB::TCPHandler::receiveHello() @ 0xf8c55a2 in /usr/bin/clickhouse
1. DB::TCPHandler::runImpl() @ 0xf8be569 in /usr/bin/clickhouse
2. DB::TCPHandler::run() @ 0xf8d1529 in /usr/bin/clickhouse
3. Poco::Net::TCPServerConnection::start() @ 0x11f84caf in /usr/bin/clickhouse
4. Poco::Net::TCPServerDispatcher::run() @ 0x11f866c1 in /usr/bin/clickhouse
5. Poco::PooledThread::run() @ 0x120bcde9 in /usr/bin/clickhouse
6. Poco::ThreadImpl::runnableEntry(void*) @ 0x120b8c4a in /usr/bin/clickhouse
7. start_thread @ 0x8fb7 in /usr/lib/x86_64-linux-gnu/libpthread-2.29.so
8. __clone @ 0xfa1af in /usr/lib/x86_64-linux-gnu/libc-2.29.so
(version 21.3.4.25 (official build))
2021.04.03 20:00:30.641361 [ 9027 ] {} <Trace> TCPHandlerFactory: TCP Request. Address: [::ffff:94.232.41.116]:57431
2021.04.03 20:00:30.641530 [ 9027 ] {} <Error> ServerErrorHandler: Code: 101, e.displayText() = DB::NetException: Unexpected packet from client, Stack trace (when copying this message, always include the lines below):
0. DB::TCPHandler::receiveHello() @ 0xf8c55a2 in /usr/bin/clickhouse
1. DB::TCPHandler::runImpl() @ 0xf8be569 in /usr/bin/clickhouse
2. DB::TCPHandler::run() @ 0xf8d1529 in /usr/bin/clickhouse
3. Poco::Net::TCPServerConnection::start() @ 0x11f84caf in /usr/bin/clickhouse
4. Poco::Net::TCPServerDispatcher::run() @ 0x11f866c1 in /usr/bin/clickhouse
5. Poco::PooledThread::run() @ 0x120bcde9 in /usr/bin/clickhouse
6. Poco::ThreadImpl::runnableEntry(void*) @ 0x120b8c4a in /usr/bin/clickhouse
7. start_thread @ 0x8fb7 in /usr/lib/x86_64-linux-gnu/libpthread-2.29.so
8. __clone @ 0xfa1af in /usr/lib/x86_64-linux-gnu/libc-2.29.so
(version 21.3.4.25 (official build))
```
I have no idea who is `94.232.41.116` (probably bot) but it looks like he is the reason. | https://github.com/ClickHouse/ClickHouse/issues/22579 | https://github.com/ClickHouse/ClickHouse/pull/22591 | a9eb7a7c7e9592c0a62be0b54fbcc6298e46d50e | f78c846bdf9b02ffff2fbc9c5f49571c7b01eff3 | "2021-04-03T23:08:20Z" | c++ | "2021-04-05T01:32:54Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,573 | ["src/Databases/DatabaseOnDisk.cpp", "src/Interpreters/InterpreterCreateQuery.cpp", "src/Interpreters/InterpreterCreateQuery.h", "src/Interpreters/InterpreterSystemQuery.cpp", "src/TableFunctions/parseColumnsListForTableFunction.cpp", "tests/queries/0_stateless/01269_create_with_null.reference", "tests/queries/0_stateless/01269_create_with_null.sql"] | data_type_default_nullable=1 in default profile prevent clickhouse from start | **How to reproduce**
Clickhouse version 21.5
```
cat /etc/clickhouse-server/users.xml
<?xml version="1.0"?>
<yandex>
<!-- Profiles of settings. -->
<profiles>
<!-- Default settings. -->
<default>
<data_type_default_nullable>1</data_type_default_nullable>
<load_balancing>random</load_balancing>
</default>
....
2021.04.04 01:23:42.453678 [ 29048 ] {} <Error> Application: DB::Exception: Nested type Array(UInt64) cannot be inside Nullable type: Cannot attach table `system`.`crash_log` from metadata file /var/lib/clickhouse/metadata/system/crash_log.sql from query ATTACH TABLE system.crash_log (`event_date` Date, `event_time` DateTime, `timestamp_ns` UInt64, `signal` Int32, `thread_id` UInt64, `query_id` String, `trace` Array(UInt64), `trace_full` Array(String), `version` String, `revision` UInt32, `build_id` String) ENGINE = MergeTree ORDER BY (event_date, event_time) SETTINGS index_granularity = 8192: while loading database `system` from path /var/lib/clickhouse/metadata/system
``` | https://github.com/ClickHouse/ClickHouse/issues/22573 | https://github.com/ClickHouse/ClickHouse/pull/23185 | 2634bccfc2457fbe65a4492a2f5a03b34fc7d3ec | 138c6ae2286acc8aacd9d1ec95ad4ac8d598345b | "2021-04-03T22:26:02Z" | c++ | "2021-04-17T13:13:42Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,563 | ["src/Columns/IColumnDummy.h", "tests/queries/0_stateless/01787_arena_assert_column_nothing.reference", "tests/queries/0_stateless/01787_arena_assert_column_nothing.sql"] | Failed assertion in Arena: additional_bytes > 0 | **Describe the bug**
https://clickhouse-test-reports.s3.yandex.net/22534/0733144b4a355394fecb837ba01af76a50e3fa05/fuzzer_debug/server.log
**How to reproduce**
`SELECT emptyArrayToSingle(arrayFilter(x -> (x != inf), arrayJoin([[1024], []]))) FROM system.one ANY LEFT JOIN (SELECT dummy, [257], NULL, dummy AS value) AS js2 USING (dummy) GROUP BY emptyArrayToSingle(arrayFilter(x -> (x != 1.), arrayJoin([[]])))`
| https://github.com/ClickHouse/ClickHouse/issues/22563 | https://github.com/ClickHouse/ClickHouse/pull/22565 | 72cf7b01e88a4c69fddd687a933d3cc075a52c98 | 0e1035735ce3e6d96daeb9d5c1ad7e7687b2c3eb | "2021-04-03T19:10:14Z" | c++ | "2021-04-04T12:38:17Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,517 | ["src/Interpreters/ExecuteScalarSubqueriesVisitor.cpp", "tests/queries/0_stateless/01247_some_msan_crashs_from_22517.reference", "tests/queries/0_stateless/01247_some_msan_crashs_from_22517.sql"] | ASan report in ExecuteScalarSubqueriesMatcher | **Describe the bug**
https://clickhouse-test-reports.s3.yandex.net/22475/2952cb296de0145a458d08dcd55365b0165c0248/fuzzer_asan/server.log
**How to reproduce**
```
SELECT x FROM (SELECT dummy AS x, plus(ignore(ignore(ignore(ignore('-922337203.6854775808', ignore(NULL)), ArrLen = 256, ignore(100, Arr.C3, ignore(NULL), (SELECT 10.000100135803223, count(*) FROM system.time_zones) > NULL)))), dummy, 65535) AS dummy ORDER BY ignore(-2) ASC, identity(x) DESC NULLS FIRST) FORMAT Null
``` | https://github.com/ClickHouse/ClickHouse/issues/22517 | https://github.com/ClickHouse/ClickHouse/pull/26428 | ccf9d2fd7f462155325619c368be35081958e3f3 | f3a5d3227a153fcf077f5d3e6bd4496a0a55959d | "2021-04-02T18:34:14Z" | c++ | "2021-07-16T22:11:55Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,491 | ["src/Interpreters/ApplyWithSubqueryVisitor.cpp", "src/Interpreters/ApplyWithSubqueryVisitor.h", "src/Interpreters/InterpreterCreateQuery.cpp", "tests/queries/0_stateless/01711_cte_subquery_fix.sql"] | create view statement support CTE expression |
such as
```
create view view1 as
with t as (select number n from numbers(3))
select n from t
``` | https://github.com/ClickHouse/ClickHouse/issues/22491 | https://github.com/ClickHouse/ClickHouse/pull/22657 | c8bcfe89ad6fa1814154edc4a7f22d649310bc83 | 9b546f3b8963f542822d90c8ca9013e617ed772b | "2021-04-02T08:23:31Z" | c++ | "2021-04-14T23:01:10Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,433 | ["src/IO/PeekableReadBuffer.cpp", "src/Server/HTTP/ReadHeaders.cpp"] | Get 'Malformed message: Field name is invalid or no colon found' for some very specific requests | **Describe the bug**
When the requests are done in a very specific environment, they got an error from ClickHouse. The partially it was fixed in https://github.com/ClickHouse/ClickHouse/pull/21936
**Does it reproduce on recent release?**
It's reproducible with docker image `yandex/clickhouse-server:latest` having digest `sha256:d359e6cff39486d2563cd16a307e0981ea6150760d7589b35e0e76ee7ba889ce`
**How to reproduce**
The very precise case for reproduction is present in https://github.com/Felixoid/ch-forms-issue
**Expected behavior**
The requests should work | https://github.com/ClickHouse/ClickHouse/issues/22433 | https://github.com/ClickHouse/ClickHouse/pull/22518 | 48af7a898cb8e987f5eadccb0eed520eeaeffa4e | aa47eb7d5e6b15a7963eae32bf39f316f064327d | "2021-04-01T10:07:43Z" | c++ | "2021-04-07T13:22:38Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,432 | ["base/mysqlxx/Pool.h", "src/Databases/DatabaseFactory.cpp", "src/Storages/StorageMaterializeMySQL.cpp", "tests/integration/test_materialize_mysql_database/materialize_with_ddl.py", "tests/integration/test_materialize_mysql_database/test.py"] | ΠΡΠΈΠ±ΠΊΠ° ClickHouse Code: 10, e.displayText() = DB::Exception: Not found column equals(catalog_id, 1041) in block | ΠΠΌΠ΅Π΅ΡΡΡ Materialized Π±Π°Π·Π°, Π΄Π°Π½Π½ΡΠ΅ ΡΠ΅ΠΏΠ»ΠΈΡΠΈΡΡΡΡΡ Π½ΠΎΡΠΌΠ°Π»ΡΠ½ΠΎ, Π² Π±Π°Π·Π΅ Π΄Π°Π½Π½ΡΠ΅ Π΅ΡΡΡ
ΠΡΠ»ΠΈ Π²ΡΠΏΠΎΠ»Π½ΠΈΡΡ Π·Π°ΠΏΡΠΎΡ
```
SELECT
DISTINCT P.id,
P.name,
P.catalog_id
FROM products P
WHERE
P.name ILIKE '%ΠΠ΅Π³ΠΊΠΈΠ΅%'
```
Π’ΠΎ ΠΏΠΎΠ»ΡΡΠΈΠΌ ΡΠ΅Π·ΡΠ»ΡΡΠ°Ρ:
` |name |catalog_id|brand_id|
---|----------------------------------------------------------------------------------------------------|----------|--------|
915|ΠΠΎΠ΄Π²Π΅ΡΠΊΠ° "ΠΠ΅Π³ΠΊΠΈΠ΅" | 5287| 15837|
990|ΠΡΠΎΡΡΠΎΠ²ΠΊΠΈ/ΠΡΠΎΡΡΠΎΠ²ΠΊΠΈ ΡΠ΅ΠΊΡΡΠΈΠ»ΡΠ½ΡΠ΅/ΠΡΠΎΡΡΠΎΠ²ΠΊΠΈ ΠΆΠ΅Π½ΡΠΊΠΈΠ΅ Π»Π΅ΡΠ½ΠΈΠ΅/ΠΊΡΠΎΡΡΠΎΠ²ΠΊΠΈ Π»Π΅Π³ΠΊΠΈΠ΅/ΠΡΠΎΡΡΠΎΠ²ΠΊΠΈ ΡΠΏΠΎΡΡΠΈΠ²Π½ΡΠ΅ | 1053| 24390|
781|ΠΡΡΠΊΠΈ ΠΆΠ΅Π½ΡΠΊΠΈΠ΅ / ΠΡΡΠΊΠΈ ΠΏΡΡΠΌΡΠ΅ / ΠΠ΅Π³ΠΊΠΈΠ΅ Π±ΡΡΠΊΠΈ Π½Π° ΡΠ΅Π·ΠΈΠ½ΠΊΠ΅ | 1041| 1176|`
ΠΠΎ Π΅ΡΠ»ΠΈ Π² Π·Π°ΠΏΡΠΎΡ Π΄ΠΎΠ±Π°Π²ΠΈΡΡ AND catalog_id = N
```
SELECT
DISTINCT P.id,
P.name,
P.catalog_id
FROM products P
WHERE
P.name ILIKE '%ΠΠ΅Π³ΠΊΠΈΠ΅%' AND P.catalog_id = 5287;
```
ΠΠ»ΠΈ ΠΆΠ΅ ΡΠ°ΠΊ:
```
SELECT
DISTINCT P.id,
P.name,
P.catalog_id,
P.brand_id
FROM products P
WHERE
P.catalog_id = 5287 AND P.brand_id = 15837;
```
Π’ΠΎ ΠΏΠΎΠ»ΡΡΠ°Ρ ΠΎΡΠΈΠ±ΠΊΠΈ
```
SQL Error [10]: ClickHouse exception, code: 10, Code: 10, e.displayText() = DB::Exception: Not found column equals(catalog_id, 5287) in block: while executing 'INPUT : 1 -> equals(catalog_id, 5287) UInt8 : 1' (version 21.3.4.25 (official build))
```
```
SQL Error [10]: ClickHouse exception, code: 10, Code: 10, e.displayText() = DB::Exception: Not found column equals(brand_id, 15837) in block: while executing 'INPUT : 0 -> equals(brand_id, 15837) UInt8 : 0' (version 21.3.4.25 (official build))
```
ΠΠΎΡΠ΅ΠΌΡ ΡΠ°ΠΊ ΠΏΡΠΎΠΈΡΡ
ΠΎΠ΄ΠΈΡ? ΠΊΠ°ΠΊ Π²ΡΠΉΡΠΈ ΠΈΠ· ΡΡΠΎΠΉ ΡΠΈΡΡΠ°ΡΠΈΠΈ?
Π‘ΡΡΡΠΊΡΡΡΠ°
```
CREATE TABLE analyzer.products
(
`id` Int32,
`product_id` Int32,
`catalog_id` Int32,
`brand_id` Int32,
`name` Nullable(String),
`description` Nullable(String),
`supplier` Nullable(String),
`marketplace` String,
`letter` String,
`isNew` UInt8,
`isSoldOut` UInt8,
`created` DateTime,
`updated` DateTime,
`_sign` Int8 MATERIALIZED 1,
`_version` UInt64 MATERIALIZED 1
)
ENGINE = ReplacingMergeTree(_version)
PARTITION BY intDiv(id,
4294967)
ORDER BY (product_id,
catalog_id,
brand_id,
letter,
updated,
id)
SETTINGS index_granularity = 8192
``` | https://github.com/ClickHouse/ClickHouse/issues/22432 | https://github.com/ClickHouse/ClickHouse/pull/23200 | 738d8a757bf03f91be660bab0528f9405eecc08c | 70c89eeff6d626293fe285503064f7045be32cb2 | "2021-04-01T08:22:29Z" | c++ | "2021-04-20T17:05:07Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,408 | ["src/AggregateFunctions/QuantileTDigest.h", "tests/queries/0_stateless/00273_quantiles.reference", "tests/queries/0_stateless/00725_quantiles_shard.reference"] | quantileTDigest inaccuracy with extreme quanties. | **Use case**
Clickhouse version 21.4
```
SELECT
quantileTiming(0.95)(key) AS timing,
quantileExact(0.95)(key) AS exact,
quantileTDigest(0.95)(key) AS tdigest
FROM
(
SELECT
9000 AS key,
2 AS count
UNION ALL
SELECT
3000,
11
UNION ALL
SELECT
1000,
26
)
ARRAY JOIN range(count) AS s
Query id: addce63f-0b75-46e2-b896-712d66711fb0
ββtimingββ¬βexactββ¬ββtdigestββ
β 9000 β 9000 β 8123.076 β
ββββββββββ΄ββββββββ΄βββββββββββ
SELECT
quantileTiming(0.9)(key) AS timing,
quantileExact(0.9)(key) AS exact,
quantileTDigest(0.9)(key) AS tdigest
FROM
(
SELECT key
FROM
(
SELECT
9000 AS key,
2 AS count
UNION ALL
SELECT
3000,
11
UNION ALL
SELECT
1000,
26
)
ARRAY JOIN range(count) AS s
ORDER BY key ASC
)
Query id: e92e3d07-3b97-4155-aa10-9a15544d9312
ββtimingββ¬βexactββ¬βββtdigestββ
β 3000 β 3000 β 6323.0757 β
ββββββββββ΄ββββββββ΄ββββββββββββ
```
Probably related: https://github.com/tdunning/t-digest/issues/154 | https://github.com/ClickHouse/ClickHouse/issues/22408 | https://github.com/ClickHouse/ClickHouse/pull/23314 | 9bb4d8769f1064ada4cce6b26d8ff61c11356965 | 013555907cb17a7a13f4184c2e0224fb8b4f09cc | "2021-03-31T11:25:52Z" | c++ | "2021-04-27T03:57:44Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,406 | ["src/Processors/Formats/Impl/CSVRowInputFormat.cpp", "tests/queries/0_stateless/01818_input_format_with_names_use_header.reference", "tests/queries/0_stateless/01818_input_format_with_names_use_header.sh"] | Disabling `input_format_with_names_use_header` discards all the input | **Describe the bug**
When you set the setting `input_format_with_names_use_header` to `0`, `INSERT` does not actually insert rows.
**How to reproduce**
* Which ClickHouse server version to use: git master `a21fe0b492cbc8628126a3cd493b83e82abf9978`, checked out on 2021-03-31
* Which interface to use: the native command-line client
* Non-default settings, if any: `input_format_with_names_use_header` = `0`
* `CREATE TABLE` statements for all tables involved:
```sql
CREATE TABLE csvtest
(
`t` String
)
ENGINE = MergeTree
ORDER BY t
```
* Sample data for all these tables
`test.csv`:
```csv
t
testdata1
testdata2
```
* Queries to run that lead to unexpected result:
```
% clickhouse-client --input_format_with_names_use_header 0 --query "INSERT INTO csvtest FORMAT CSVWithNames" < test.csv
```
**Expected behavior**
Two rows `('testdata1'), ('testdata2')` will be inserted to the table `csvtest`.
**Error message and/or stacktrace**
Nothing. It silently discards the input and inserts nothing to the table.
**Additional context**
It works as expected if you set `input_format_with_names_use_header` to `1`.
| https://github.com/ClickHouse/ClickHouse/issues/22406 | https://github.com/ClickHouse/ClickHouse/pull/23202 | 632a5288fa7e12cc0a87acb2921f62195687ea8e | 16e77150393030aca7545aa1a511c8a50a895296 | "2021-03-31T09:31:56Z" | c++ | "2021-04-20T17:00:57Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,388 | ["src/Interpreters/MergeJoin.cpp", "src/Interpreters/MergeJoin.h", "tests/queries/0_stateless/01785_pmj_lc_bug.reference", "tests/queries/0_stateless/01785_pmj_lc_bug.sql"] | ASan report in MergeJoin. | **Describe the bug**
https://clickhouse-test-reports.s3.yandex.net/22328/43d9972f18d43c6736c08e67c01deb64b733109a/fuzzer_asan/server.log
**How to reproduce**
`SELECT * FROM (SELECT number AS l FROM system.numbers LIMIT 3) ANY LEFT JOIN (SELECT toLowCardinality(number) AS r FROM system.numbers LIMIT 1025) ON (l + 1025) = (r * 1)`
```
Changed settings: min_insert_block_size_rows = '0', min_insert_block_size_bytes = '0', max_threads = '16', totals_mode = 'after_having_auto', log_queries = '1', join_use_nulls = '0', joined_subquery_requires_alias = '0', max_rows_to_group_by = '100000', group_by_overflow_mode = 'any', max_bytes_in_join = '100',
join_algorithm = 'auto',
max_partitions_per_insert_block = '100', mutations_sync = '1', aggregate_functions_null_for_empty = '1'
```
Maybe the reason is the same as #22386.
PS. We should not encourage people to use merge join algorithm until the issue will be fixed. | https://github.com/ClickHouse/ClickHouse/issues/22388 | https://github.com/ClickHouse/ClickHouse/pull/22510 | 143f4b59a00747415931b9eef64f51b17740914b | 30ece2c28f3044e0ae8b8edb3a93fabe7358b897 | "2021-03-31T01:00:39Z" | c++ | "2021-04-03T09:54:34Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,379 | ["docker/test/fasttest/run.sh", "src/Interpreters/ExpressionAnalyzer.cpp", "src/Storages/ReadInOrderOptimizer.cpp", "tests/queries/0_stateless/01833_test_collation_alvarotuso.reference", "tests/queries/0_stateless/01833_test_collation_alvarotuso.sql", "tests/queries/0_stateless/arcadia_skip_list.txt"] | ORDER BY column_name COLLATE does not work for primary keys | (you don't have to strictly follow this form)
**Describe the bug**
When using `ORDER BY column_name COLLATE 'en'`, `COLLATE` is ignored if `column_name` is the primary key
**How to reproduce**
* version 21.1.2
* `CREATE TABLE` statements for all tables involved:
```
CREATE TABLE test.test_collation
(
`v` String,
`v2` String
)
ENGINE = MergeTree
ORDER BY v
SETTINGS index_granularity = 8192
```
* Sample data:
```
insert into test.test_collation values ('A', 'A')
insert into test.test_collation values ('B', 'B')
insert into test.test_collation values ('C', 'C')
insert into test.test_collation values ('a', 'a')
insert into test.test_collation values ('b', 'b')
insert into test.test_collation values ('c', 'c')
```
* Queries to run that lead to unexpected result
Primary key
```
SELECT *
FROM test.test_collation
ORDER BY v ASC COLLATE 'en'
Query id: fa84ae7a-abe7-4886-99cd-eba7ad5d5fc4
ββvββ¬βv2ββ
β A β A β
β B β B β
β C β C β
β a β a β
β b β b β
β c β c β
βββββ΄βββββ
```
Separate column
```
SELECT *
FROM test.test_collation
ORDER BY v2 ASC COLLATE 'en'
Query id: 04401f85-3cb2-442c-8c89-e3328d1615cd
ββvββ¬βv2ββ
β a β a β
β A β A β
β b β b β
β B β B β
β c β c β
β C β C β
βββββ΄βββββ
```
**Expected behavior**
Both of these queries to return the rows in the same order
| https://github.com/ClickHouse/ClickHouse/issues/22379 | https://github.com/ClickHouse/ClickHouse/pull/23375 | 68e93959c103e1b9556c63c89036f3c99754b3c9 | 9c649932bcea896b135980f140a855b7d1b634b6 | "2021-03-30T17:56:37Z" | c++ | "2021-04-21T12:00:02Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,377 | ["docs/en/sql-reference/functions/array-functions.md", "docs/ru/sql-reference/functions/array-functions.md"] | arrayFill description in Russian | **Describe the issue**
`arrayFill`, `arrayReverseFill`, `arraySplit`, `arrayReverseSplit` descriptions are not exists in Russian documentation.
| https://github.com/ClickHouse/ClickHouse/issues/22377 | https://github.com/ClickHouse/ClickHouse/pull/22493 | 645bea04c3f457d1984d6f41ec9bb7231b5007b8 | 014b443a22dbd46562dada5bfee6c746ca2ca63b | "2021-03-30T17:08:51Z" | c++ | "2021-04-02T18:12:29Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,355 | ["src/Dictionaries/ExecutableDictionarySource.cpp", "src/Dictionaries/ExecutablePoolDictionarySource.cpp"] | Allow executable DDL dictionaries in clickhouse-local | May be useful to interface with some external program, e.g. I want to use `clickhouse-format` to beautify the queries for performance test reports.
For now, DDL dictionaries don't work for `clickhouse-local` at all (https://github.com/ClickHouse/ClickHouse/issues/22354)
We should do it through DDL, because the xml config route looks hopeless. `clickhouse-local` can't even load server's `config.xml` properly. | https://github.com/ClickHouse/ClickHouse/issues/22355 | https://github.com/ClickHouse/ClickHouse/pull/26510 | 20f03f6ed740e00a178678da7829ea5135f04e91 | 0fae3a318899ac45d80ef42352b44b3507736664 | "2021-03-30T11:25:25Z" | c++ | "2021-07-19T20:51:18Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,290 | ["src/Interpreters/TreeRewriter.cpp", "tests/queries/0_stateless/01803_untuple_subquery.reference", "tests/queries/0_stateless/01803_untuple_subquery.sql"] | Logical error: 'Cannot find column NULL in ActionsDAG result' | ```
SELECT (0.5, '92233720368547758.07', NULL), '', '1.00', untuple(('256', NULL)), NULL FROM (SELECT untuple(((NULL, untuple((('0.0000000100', (65536, NULL, (65535, 9223372036854775807), '25.7', (0.00009999999747378752, '10.25', 1048577), 65536)), '0.0000001024', '65537', NULL))), untuple((9223372036854775807, -inf, 0.5)), NULL, -9223372036854775808)), 257, 7, ('0.0001048575', (1024, NULL, (7, 3), (untuple(tuple(-NULL)), NULL, '0.0001048577', NULL), 0)), 0, (0, 0.9998999834060669, '65537'), untuple(tuple('10.25')))
2021.03.26 22:11:41.060721 [ 50 ] {fff23085-65e6-401e-8498-16aa9e971cbf} <Fatal> : Logical error: 'Cannot find column NULL in ActionsDAG result'.
2021.03.26 22:11:41.061474 [ 44 ] {} <Trace> BaseDaemon: Received signal 6
2021.03.26 22:11:41.062183 [ 156 ] {} <Fatal> BaseDaemon: ########################################
2021.03.26 22:11:41.062561 [ 156 ] {} <Fatal> BaseDaemon: (version 21.4.1.6356, build id: 54FE96D1BDF0D7C238B0D1C7498601AFB1DA7D73) (from thread 50) (query_id: fff23085-65e6-401e-8498-16aa9e971cbf) Received signal Aborted (6)
2021.03.26 22:11:41.062953 [ 156 ] {} <Fatal> BaseDaemon:
2021.03.26 22:11:41.063331 [ 156 ] {} <Fatal> BaseDaemon: Stack trace: 0x7f901d9d618b 0x7f901d9b5859 0x1198ea96 0x1198eba5 0x11a95e31 0x1a9e2cea 0x1c306e85 0x1c2ff373 0x1c2e6674 0x1c2e620a 0x1b2804cf 0x1b4a4421 0x1b4a28ea 0x1be86812 0x1be92e58 0x1f942bcc 0x1f9433d0 0x1fa7fb73 0x1fa7c9fd 0x1fa7b888 0x7f901db8b609 0x7f901dab2293
2021.03.26 22:11:41.063750 [ 156 ] {} <Fatal> BaseDaemon: 4. raise @ 0x4618b in /usr/lib/x86_64-linux-gnu/libc-2.31.so
2021.03.26 22:11:41.063934 [ 156 ] {} <Fatal> BaseDaemon: 5. abort @ 0x25859 in /usr/lib/x86_64-linux-gnu/libc-2.31.so
2021.03.26 22:11:41.198666 [ 156 ] {} <Fatal> BaseDaemon: 6. ./obj-x86_64-linux-gnu/../src/Common/Exception.cpp:51: 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&) @ 0x1198ea96 in /workspace/clickhouse
2021.03.26 22:11:41.322932 [ 156 ] {} <Fatal> BaseDaemon: 7. ./obj-x86_64-linux-gnu/../src/Common/Exception.cpp:58: DB::Exception::Exception(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, int, bool) @ 0x1198eba5 in /workspace/clickhouse
2021.03.26 22:11:41.423148 [ 156 ] {} <Fatal> BaseDaemon: 8. ./obj-x86_64-linux-gnu/../src/Common/Exception.h:40: DB::Exception::Exception<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&>(int, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&) @ 0x11a95e31 in /workspace/clickhouse
2021.03.26 22:11:42.714139 [ 156 ] {} <Fatal> BaseDaemon: 9. ./obj-x86_64-linux-gnu/../src/Interpreters/ActionsDAG.cpp:884: DB::ActionsDAG::merge(DB::ActionsDAG&&, DB::ActionsDAG&&) @ 0x1a9e2cea in /workspace/clickhouse
2021.03.26 22:11:42.848570 [ 156 ] {} <Fatal> BaseDaemon: 10. ./obj-x86_64-linux-gnu/../src/Processors/QueryPlan/Optimizations/mergeExpressions.cpp:34: DB::QueryPlanOptimizations::tryMergeExpressions(DB::QueryPlan::Node*, std::__1::list<DB::QueryPlan::Node, std::__1::allocator<DB::QueryPlan::Node> >&) @ 0x1c306e85 in /workspace/clickhouse
2021.03.26 22:11:42.943667 [ 156 ] {} <Fatal> BaseDaemon: 11. ./obj-x86_64-linux-gnu/../src/Processors/QueryPlan/Optimizations/optimizeTree.cpp:76: DB::QueryPlanOptimizations::optimizeTree(DB::QueryPlanOptimizationSettings const&, DB::QueryPlan::Node&, std::__1::list<DB::QueryPlan::Node, std::__1::allocator<DB::QueryPlan::Node> >&) @ 0x1c2ff373 in /workspace/clickhouse
2021.03.26 22:11:43.173463 [ 156 ] {} <Fatal> BaseDaemon: 12. ./obj-x86_64-linux-gnu/../src/Processors/QueryPlan/QueryPlan.cpp:345: DB::QueryPlan::optimize(DB::QueryPlanOptimizationSettings const&) @ 0x1c2e6674 in /workspace/clickhouse
2021.03.26 22:11:43.394052 [ 156 ] {} <Fatal> BaseDaemon: 13. ./obj-x86_64-linux-gnu/../src/Processors/QueryPlan/QueryPlan.cpp:148: DB::QueryPlan::buildQueryPipeline(DB::QueryPlanOptimizationSettings const&, DB::BuildQueryPipelineSettings const&) @ 0x1c2e620a in /workspace/clickhouse
2021.03.26 22:11:43.880859 [ 156 ] {} <Fatal> BaseDaemon: 14. ./obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectWithUnionQuery.cpp:300: DB::InterpreterSelectWithUnionQuery::execute() @ 0x1b2804cf in /workspace/clickhouse
2021.03.26 22:11:44.505869 [ 156 ] {} <Fatal> BaseDaemon: 15. ./obj-x86_64-linux-gnu/../src/Interpreters/executeQuery.cpp:550: DB::executeQueryImpl(char const*, char const*, DB::Context&, bool, DB::QueryProcessingStage::Enum, bool, DB::ReadBuffer*) @ 0x1b4a4421 in /workspace/clickhouse
2021.03.26 22:11:45.158766 [ 156 ] {} <Fatal> BaseDaemon: 16. ./obj-x86_64-linux-gnu/../src/Interpreters/executeQuery.cpp:908: DB::executeQuery(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, DB::Context&, bool, DB::QueryProcessingStage::Enum, bool) @ 0x1b4a28ea in /workspace/clickhouse
2021.03.26 22:11:45.818858 [ 156 ] {} <Fatal> BaseDaemon: 17. ./obj-x86_64-linux-gnu/../src/Server/TCPHandler.cpp:289: DB::TCPHandler::runImpl() @ 0x1be86812 in /workspace/clickhouse
2021.03.26 22:11:46.526029 [ 156 ] {} <Fatal> BaseDaemon: 18. ./obj-x86_64-linux-gnu/../src/Server/TCPHandler.cpp:1520: DB::TCPHandler::run() @ 0x1be92e58 in /workspace/clickhouse
2021.03.26 22:11:46.592564 [ 156 ] {} <Fatal> BaseDaemon: 19. ./obj-x86_64-linux-gnu/../contrib/poco/Net/src/TCPServerConnection.cpp:43: Poco::Net::TCPServerConnection::start() @ 0x1f942bcc in /workspace/clickhouse
2021.03.26 22:11:46.695511 [ 156 ] {} <Fatal> BaseDaemon: 20. ./obj-x86_64-linux-gnu/../contrib/poco/Net/src/TCPServerDispatcher.cpp:113: Poco::Net::TCPServerDispatcher::run() @ 0x1f9433d0 in /workspace/clickhouse
2021.03.26 22:11:46.790577 [ 156 ] {} <Fatal> BaseDaemon: 21. ./obj-x86_64-linux-gnu/../contrib/poco/Foundation/src/ThreadPool.cpp:199: Poco::PooledThread::run() @ 0x1fa7fb73 in /workspace/clickhouse
2021.03.26 22:11:46.879621 [ 156 ] {} <Fatal> BaseDaemon: 22. ./obj-x86_64-linux-gnu/../contrib/poco/Foundation/src/Thread.cpp:56: Poco::(anonymous namespace)::RunnableHolder::run() @ 0x1fa7c9fd in /workspace/clickhouse
2021.03.26 22:11:46.967127 [ 156 ] {} <Fatal> BaseDaemon: 23. ./obj-x86_64-linux-gnu/../contrib/poco/Foundation/src/Thread_POSIX.cpp:345: Poco::ThreadImpl::runnableEntry(void*) @ 0x1fa7b888 in /workspace/clickhouse
2021.03.26 22:11:46.967557 [ 156 ] {} <Fatal> BaseDaemon: 24. start_thread @ 0x9609 in /usr/lib/x86_64-linux-gnu/libpthread-2.31.so
2021.03.26 22:11:46.967844 [ 156 ] {} <Fatal> BaseDaemon: 25. clone @ 0x122293 in /usr/lib/x86_64-linux-gnu/libc-2.31.so
2021.03.26 22:11:48.065827 [ 156 ] {} <Fatal> BaseDaemon: Calculated checksum of the binary: 5DF9743F702F7C2A044EDD2C9697E25A. There is no information about the reference checksum.
``` | https://github.com/ClickHouse/ClickHouse/issues/22290 | https://github.com/ClickHouse/ClickHouse/pull/22991 | ee9aaab4bcf8b7f98b485d2b6f30f1a0c41c3988 | e731dfe650e4c77aafbd608ab379e4372ebbcd6c | "2021-03-29T11:15:12Z" | c++ | "2021-04-13T06:53:13Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,234 | ["programs/client/ConnectionParameters.cpp", "src/Client/Connection.h", "src/Interpreters/Cluster.cpp", "src/Storages/Distributed/DirectoryMonitor.cpp", "tests/queries/0_stateless/00933_test_fix_extra_seek_on_compressed_cache.reference", "tests/queries/0_stateless/01598_memory_limit_zeros.sql"] | Network compression should be disabled when interacting via localhost. | **Describe the situation**
```
$ ./clickhouse-21.3.3 client --query "SELECT * FROM system.numbers_mt FORMAT Native" | pv > /dev/null
^C,1GiB 0:00:45 [ 710MiB/s] [ <=> ]
$ ./clickhouse-21.3.3 client --compress 0 --query "SELECT * FROM system.numbers_mt FORMAT Native" | pv > /dev/null
^C,2GiB 0:00:12 [1,48GiB/s] [ <=> ]
```
| https://github.com/ClickHouse/ClickHouse/issues/22234 | https://github.com/ClickHouse/ClickHouse/pull/22237 | 75c4728787d4aa38a91090a8aa582897db32409a | 7f3a40e1b031777348f1daade7c2bd0160c74f2a | "2021-03-29T00:34:02Z" | c++ | "2021-04-18T00:13:54Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,221 | ["docs/en/development/build-osx.md", "src/Access/MemoryAccessStorage.h"] | LDAP: changing groups for user makes Clickhouse fail to log in | **Describe the bug**
Clickhouse fails to log users after changing groups at LDAP for one user
**Does it reproduce on recent release?**
I've checked It on 21.2.5.5 and 21.3.4.25
**How to reproduce**
E.g. there is LDAP user *user_1* and there are two LDAP groups *role_1* and *role_2*, which are mapped to the Clickhouse roles with the same names.
At the beginning *user_1* is only at *role_1* group
1. Log *user_1* in by clickhouse-client and check grants:
```
SHOW GRANTS
ββGRANTSββββββββββββββββββββββββββββββββββββββββββ
β GRANT role1 TO user_1 β
ββββββββββββββββββββββββββββββββββββββββββββββββββ
```
2. Exclude *user_1* from *role_1* and assign him to the *role_2* group
3. Try to log him in by clickhouse-client again. Login process hangs forever. Also other users can't log in too.
**Expected behavior**
User will have updated grants after the re-login
**Error message and/or stacktrace**
I found no logs for that :(
**Additional context**
Clickhouse on CentOS, freeipa as a LDAP
| https://github.com/ClickHouse/ClickHouse/issues/22221 | https://github.com/ClickHouse/ClickHouse/pull/24431 | 38493bde487ce48e37f0fdbcb2894f55d78298c3 | e2460164bc1f6b44c22b6f20533ac5f1521d7138 | "2021-03-28T12:02:58Z" | c++ | "2021-05-31T19:14:13Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,160 | ["tests/queries/0_stateless/02508_index_analysis_to_date_timezone.reference", "tests/queries/0_stateless/02508_index_analysis_to_date_timezone.sql"] | Timezone: toDate() works different in different query clauses | **Describe the bug**
I have a table with column `date DateTime('Asia/Kamchatka')`, server/client timezone is `'Europe/Moscow'`. Two queries return different results:
```
local :) select uid, date, toDate(date) = toDate('2021-03-24') res FROM table WHERE res = 1
SELECT
uid,
date,
toDate(date) = toDate('2021-03-24') AS res
FROM table
WHERE res = 1
ββuidβββββββββββββββββββββββββββββββββββ¬ββββββββββdateββββββββ¬βresββ
β 4c36abda-8bd8-11eb-8204-005056aa8bf6 β 2021-03-24 01:04:27 β 1 β
β 4c408902-8bd8-11eb-8204-005056aa8bf6 β 2021-03-24 01:04:27 β 1 β
β 4c5bf20a-8bd8-11eb-8204-005056aa8bf6 β 2021-03-24 01:04:27 β 1 β
β 4c61623a-8bd8-11eb-8204-005056aa8bf6 β 2021-03-24 01:04:27 β 1 β
β 4c6efab2-8bd8-11eb-a952-005056aa8bf6 β 2021-03-24 01:04:27 β 1 β
ββββββββββββββββββββββββββββββββββββββββ΄ββββββββββββββββββββββ΄ββββββ
```
AND
```
local :) select uid, date, toDate(date) = toDate('2021-03-24') res FROM table WHERE toDate(date) = toDate('2021-03-24');
SELECT
uid,
date,
toDate(date) = toDate('2021-03-24') AS res
FROM table
WHERE toDate(date) = toDate('2021-03-24')
Ok.
0 rows in set. Elapsed: 0.252 sec.
```
It seems like position for toDate in query matters - column timezone doesn't work in `where` clause.
**How to reproduce**
ClickHouse client version 20.8.4.11 (official build).
Connecting to localhost:9001 as user default.
Connected to ClickHouse server version 20.8.4 revision 54438.
**Expected behavior**
Same results.
| https://github.com/ClickHouse/ClickHouse/issues/22160 | https://github.com/ClickHouse/ClickHouse/pull/44355 | 21d9e7ebc3a01bded5c616cf339c6ac4c7a8df68 | 31348a0c2b9c6ae4cfa503bf786b178e4328cd7c | "2021-03-26T11:55:08Z" | c++ | "2022-12-27T11:53:46Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,158 | ["programs/client/Suggest.cpp", "programs/client/Suggest.h", "tests/queries/0_stateless/01676_long_clickhouse_client_autocomplete.reference", "tests/queries/0_stateless/01676_long_clickhouse_client_autocomplete.sh"] | Unexpected errors in read-only mode | **Describe the bug**
When connecting via read-only user to clickhouse, unexpected exceptions are logged both by clickhouse-client and clickhouse-server.
**Does it reproduce on recent release?**
[The list of releases](https://github.com/ClickHouse/ClickHouse/blob/master/utils/list-versions/version_date.tsv)
Reproduces on 21.3.3.14-lts
**How to reproduce**
To reproduce this issue, official RPMs may be used. It doesn't reproduce with docker image yandex/clickhouse-{client,server}
* run fedora in docker:
`$ docker run --privileged -ti registry.fedoraproject.org/fedora:rawhide /bin/bash`
* install dependencies, wget and a text editor:
` # dnf install initscripts wget nano`
* download clickhouse 21.3.3.14 rpms and install it:
```
# cd /root
# wget https://github.com/ClickHouse/ClickHouse/releases/download/v21.3.3.14-lts/clickhouse-client-21.3.3.14-2.noarch.rpm
# wget https://github.com/ClickHouse/ClickHouse/releases/download/v21.3.3.14-lts/clickhouse-common-static-21.3.3.14-2.x86_64.rpm
# wget https://github.com/ClickHouse/ClickHouse/releases/download/v21.3.3.14-lts/clickhouse-server-21.3.3.14-2.noarch.rpm
# rpm -i -U -v -h clickhouse-client-21.3.3.14-2.noarch.rpm clickhouse-common-static-21.3.3.14-2.x86_64.rpm clickhouse-server-21.3.3.14-2.noarch.rpm
```
* uncomment `<access_management>1</access_management>` line in file `/etc/clickhouse-server/users.xml`
* start clickhouse server:
`/etc/init.d/clickhouse-server start`
* connect to clickhouse server and create read-only user:
```
# clickhouse-client
ClickHouse client version 21.3.3.14 (official build).
Connecting to localhost:9000 as user default.
Connected to ClickHouse server version 21.3.3 revision 54447.
e9cae3b6abc2 :) create user readonlyuser identified with plaintext_password by 'password' settings profile 'readonly'
CREATE USER readonlyuser IDENTIFIED WITH plaintext_password BY 'password' SETTINGS PROFILE readonly
Query id: 32e34c2d-0b7d-4bb2-8806-abb5789d8a43
Ok.
0 rows in set. Elapsed: 0.003 sec.
e9cae3b6abc2 :) Bye.
```
* now connect as read-only user
`clickhouse-client -u readonlyuser --ask-password`
**Expected behavior**
Expected that it works without any errors.
**Error message and/or stacktrace**
Error on client:
```
# clickhouse-client -u readonlyuser --ask-password
ClickHouse client version 21.3.3.14 (official build).
Password for user (readonlyuser):
Connecting to localhost:9000 as user readonlyuser.
Connected to ClickHouse server version 21.3.3 revision 54447.
e9cae3b6abc2 :) Cannot load data for command line suggestions: Code: 164, e.displayText() = DB::Exception: Received from localhost:9000. DB::Exception: Cannot modify 'system_events_show_zero_values' setting in readonly mode. (version 21.3.3.14 (official build))
```
Error on server (`/var/log/clickhouse-server/clickhouse-server.err.log`):
```
2021.03.26 09:45:58.976489 [ 259 ] {} <Error> TCPHandler: Code: 164, e.displayText() = DB::Exception: Cannot modify 'system_events_show_zero_values' setting in readonly mode, Stack trace:
0. DB::SettingsConstraints::checkImpl(DB::Settings const&, DB::SettingChange&, DB::SettingsConstraints::ReactionOnViolation) const @ 0xe6d2170 in /usr/bin/clickhouse
1. DB::SettingsConstraints::check(DB::Settings const&, DB::SettingsChanges&) const @ 0xe6d2b20 in /usr/bin/clickhouse
2. DB::TCPHandler::receiveQuery() @ 0xf8c916b in /usr/bin/clickhouse
3. DB::TCPHandler::receivePacket() @ 0xf8bfbb7 in /usr/bin/clickhouse
4. DB::TCPHandler::runImpl() @ 0xf8b83b2 in /usr/bin/clickhouse
5. DB::TCPHandler::run() @ 0xf8cad69 in /usr/bin/clickhouse
6. Poco::Net::TCPServerConnection::start() @ 0x11f7d83f in /usr/bin/clickhouse
7. Poco::Net::TCPServerDispatcher::run() @ 0x11f7f251 in /usr/bin/clickhouse
8. Poco::PooledThread::run() @ 0x120b5979 in /usr/bin/clickhouse
9. Poco::ThreadImpl::runnableEntry(void*) @ 0x120b17da in /usr/bin/clickhouse
10. start_thread @ 0x91c9 in /usr/lib64/libpthread-2.33.9000.so
11. clone @ 0x100463 in /usr/lib64/libc-2.33.9000.so
2021.03.26 09:45:58.978054 [ 259 ] {} <Error> TCPHandler: Code: 261, e.displayText() = DB::Exception: Unknown BlockInfo field number: 227213735, Stack trace:
0. DB::BlockInfo::read(DB::ReadBuffer&) @ 0xe8a6658 in /usr/bin/clickhouse
1. DB::NativeBlockInputStream::readImpl() @ 0xefdd853 in /usr/bin/clickhouse
2. DB::IBlockInputStream::read() @ 0xe8ab0a5 in /usr/bin/clickhouse
3. DB::TCPHandler::receiveUnexpectedData() @ 0xf8c9c35 in /usr/bin/clickhouse
4. DB::TCPHandler::receivePacket() @ 0xf8bfd36 in /usr/bin/clickhouse
5. DB::TCPHandler::runImpl() @ 0xf8b83b2 in /usr/bin/clickhouse
6. DB::TCPHandler::run() @ 0xf8cad69 in /usr/bin/clickhouse
7. Poco::Net::TCPServerConnection::start() @ 0x11f7d83f in /usr/bin/clickhouse
8. Poco::Net::TCPServerDispatcher::run() @ 0x11f7f251 in /usr/bin/clickhouse
9. Poco::PooledThread::run() @ 0x120b5979 in /usr/bin/clickhouse
10. Poco::ThreadImpl::runnableEntry(void*) @ 0x120b17da in /usr/bin/clickhouse
11. start_thread @ 0x91c9 in /usr/lib64/libpthread-2.33.9000.so
12. clone @ 0x100463 in /usr/lib64/libc-2.33.9000.so
2021.03.26 09:45:58.978523 [ 259 ] {} <Error> ServerErrorHandler: Code: 99, e.displayText() = DB::Exception: Unknown packet 11861 from client, Stack trace (when copying this message, always include the lines below):
0. DB::TCPHandler::receivePacket() @ 0xf8bfcfc in /usr/bin/clickhouse
1. DB::TCPHandler::runImpl() @ 0xf8b83b2 in /usr/bin/clickhouse
2. DB::TCPHandler::run() @ 0xf8cad69 in /usr/bin/clickhouse
3. Poco::Net::TCPServerConnection::start() @ 0x11f7d83f in /usr/bin/clickhouse
4. Poco::Net::TCPServerDispatcher::run() @ 0x11f7f251 in /usr/bin/clickhouse
5. Poco::PooledThread::run() @ 0x120b5979 in /usr/bin/clickhouse
6. Poco::ThreadImpl::runnableEntry(void*) @ 0x120b17da in /usr/bin/clickhouse
7. start_thread @ 0x91c9 in /usr/lib64/libpthread-2.33.9000.so
8. clone @ 0x100463 in /usr/lib64/libc-2.33.9000.so
(version 21.3.3.14 (official build))
```
**Additional context**
As stated before, it reproduces with official RPMs but doesn't reproduce with yandex/clickhouse-{client,server} docker images. | https://github.com/ClickHouse/ClickHouse/issues/22158 | https://github.com/ClickHouse/ClickHouse/pull/23040 | 86e20905e5fd38bf1d2ead8089a7f788931a484a | 35260089e0ce8b593a33aaff860eda398c6b1c56 | "2021-03-26T10:07:48Z" | c++ | "2021-04-14T10:55:25Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,157 | ["src/Functions/array/range.cpp", "tests/queries/0_stateless/01780_range_msan.reference", "tests/queries/0_stateless/01780_range_msan.sql"] | MSan: use of uninitialized value in FunctionRange::executeImpl | https://clickhouse-test-reports.s3.yandex.net/22133/33647ef3d53997b72d15df1e5abd8cf750609afc/fuzzer_msan/report.html#fail1
In debug it's a logical error.
```
SELECT arrayJoin(range(toUInt256(1048577), 100)) AS x FROM remote('127.0.0.2', system.one) WHERE x GLOBAL IN (SELECT toUInt8(arrayJoin(range(100)) + 50)) GROUP BY x ORDER BY x ASC NULLS FIRST LIMIT 10 FORMAT JSONCompact
Uninitialized bytes in __msan_check_mem_is_initialized at offset 8 inside [0x7200003ce020, 32)
==42==WARNING: MemorySanitizer: use-of-uninitialized-value
#0 0x2ea9c421 in DB::ColumnConst::ColumnConst(COW<DB::IColumn>::immutable_ptr<DB::IColumn> const&, unsigned long) obj-x86_64-linux-gnu/../src/Columns/ColumnConst.cpp:41:9
#1 0x2c46ee84 in COW<DB::IColumn>::mutable_ptr<DB::ColumnConst> COWHelper<DB::IColumn, DB::ColumnConst>::create<COW<DB::IColumn>::mutable_ptr<DB::IColumn>, unsigned long&>(COW<DB::IColumn>::mutable_ptr<DB::IColumn>&&, unsigned long&) obj-x86_64-linux-gnu/../src/Common/COW.h:285:71
#2 0x2c46ee84 in DB::IDataType::createColumnConst(unsigned long, DB::Field const&) const obj-x86_64-linux-gnu/../src/DataTypes/IDataType.cpp:108:12
#3 0x266f9596 in DB::FunctionRange::executeImpl(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long) const (/workspace/clickhouse+0x266f9596)
#4 0x12ea3cdc in DB::IFunction::executeImplDryRun(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long) const (/workspace/clickhouse+0x12ea3cdc)
#5 0x12ea359c in DB::DefaultExecutable::executeDryRun(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long) const (/workspace/clickhouse+0x12ea359c)
#6 0x13010f45 in DB::ExecutableFunctionAdaptor::executeWithoutLowCardinalityColumns(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const (/workspace/clickhouse+0x13010f45)
#7 0x1300f1d3 in DB::ExecutableFunctionAdaptor::defaultImplementationForConstantArguments(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const (/workspace/clickhouse+0x1300f1d3)
#8 0x13010cc3 in DB::ExecutableFunctionAdaptor::executeWithoutLowCardinalityColumns(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const (/workspace/clickhouse+0x13010cc3)
#9 0x13013383 in DB::ExecutableFunctionAdaptor::execute(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const (/workspace/clickhouse+0x13013383)
#10 0x2c70b05f in DB::ActionsDAG::addFunction(std::__1::shared_ptr<DB::IFunctionOverloadResolver> const&, std::__1::vector<DB::ActionsDAG::Node const*, std::__1::allocator<DB::ActionsDAG::Node const*> >, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >) obj-x86_64-linux-gnu/../src/Interpreters/ActionsDAG.cpp:168:35
#11 0x2d810a1b in DB::ScopeStack::addFunction(std::__1::shared_ptr<DB::IFunctionOverloadResolver> const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.cpp:569:51
#12 0x2d822a9c in DB::ActionsMatcher::Data::addFunction(std::__1::shared_ptr<DB::IFunctionOverloadResolver> const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.h:164:27
#13 0x2d822a9c in DB::ActionsMatcher::visit(DB::ASTFunction const&, std::__1::shared_ptr<DB::IAST> const&, DB::ActionsMatcher::Data&) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.cpp:1049:14
#14 0x2d812852 in DB::ActionsMatcher::visit(std::__1::shared_ptr<DB::IAST> const&, DB::ActionsMatcher::Data&) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.cpp:623:9
#15 0x2d81536a in DB::ActionsMatcher::visit(DB::ASTFunction const&, std::__1::shared_ptr<DB::IAST> const&, DB::ActionsMatcher::Data&) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.cpp:779:9
#16 0x2d812852 in DB::ActionsMatcher::visit(std::__1::shared_ptr<DB::IAST> const&, DB::ActionsMatcher::Data&) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.cpp:623:9
#17 0x2d7be52f in DB::InDepthNodeVisitor<DB::ActionsMatcher, true, std::__1::shared_ptr<DB::IAST> const>::visit(std::__1::shared_ptr<DB::IAST> const&) obj-x86_64-linux-gnu/../src/Interpreters/InDepthNodeVisitor.h:34:13
#18 0x2d763cf2 in DB::ExpressionAnalyzer::getRootActionsNoMakeSet(std::__1::shared_ptr<DB::IAST> const&, bool, std::__1::shared_ptr<DB::ActionsDAG>&, bool) obj-x86_64-linux-gnu/../src/Interpreters/ExpressionAnalyzer.cpp:417:48
#19 0x2d75f0bc in DB::ExpressionAnalyzer::analyzeAggregation() obj-x86_64-linux-gnu/../src/Interpreters/ExpressionAnalyzer.cpp:235:21
#20 0x2d7592de in DB::ExpressionAnalyzer::ExpressionAnalyzer(std::__1::shared_ptr<DB::IAST> const&, std::__1::shared_ptr<DB::TreeRewriterResult const> const&, DB::Context const&, unsigned long, bool, std::__1::unordered_map<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, DB::SubqueryForSet, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::allocator<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, DB::SubqueryForSet> > >) obj-x86_64-linux-gnu/../src/Interpreters/ExpressionAnalyzer.cpp:152:5
2021.03.26 01:19:40.861948 [ 113 ] {} <Trace> SystemLog (system.query_log): Flushing system log, 448 entries to flush
#21 0x2cf8c367 in DB::SelectQueryExpressionAnalyzer::SelectQueryExpressionAnalyzer(std::__1::shared_ptr<DB::IAST> const&, std::__1::shared_ptr<DB::TreeRewriterResult const> const&, DB::Context const&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&, std::__1::unordered_set<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, bool, DB::SelectQueryOptions const&, std::__1::unordered_map<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, DB::SubqueryForSet, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::allocator<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, DB::SubqueryForSet> > >) obj-x86_64-linux-gnu/../src/Interpreters/ExpressionAnalyzer.h:268:11
#22 0x2cf26f51 in std::__1::__unique_if<DB::SelectQueryExpressionAnalyzer>::__unique_single std::__1::make_unique<DB::SelectQueryExpressionAnalyzer, std::__1::shared_ptr<DB::IAST>&, std::__1::shared_ptr<DB::TreeRewriterResult const>&, DB::Context&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const>&, std::__1::unordered_set<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > >, bool, DB::SelectQueryOptions&, std::__1::unordered_map<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, DB::SubqueryForSet, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::allocator<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, DB::SubqueryForSet> > > >(std::__1::shared_ptr<DB::IAST>&, std::__1::shared_ptr<DB::TreeRewriterResult const>&, DB::Context&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const>&, std::__1::unordered_set<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > >&&, bool&&, DB::SelectQueryOptions&, std::__1::unordered_map<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, DB::SubqueryForSet, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::allocator<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, DB::SubqueryForSet> > >&&) obj-x86_64-linux-gnu/../contrib/libcxx/include/memory:2068:32
#23 0x2cf26f51 in DB::InterpreterSelectQuery::InterpreterSelectQuery(std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, std::__1::shared_ptr<DB::IBlockInputStream> const&, std::__1::optional<DB::Pipe>, std::__1::shared_ptr<DB::IStorage> const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&)::$_2::operator()(bool) const obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectQuery.cpp:414:26
#24 0x2cf16ee0 in DB::InterpreterSelectQuery::InterpreterSelectQuery(std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, std::__1::shared_ptr<DB::IBlockInputStream> const&, std::__1::optional<DB::Pipe>, std::__1::shared_ptr<DB::IStorage> const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&) obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectQuery.cpp:478:5
#25 0x2cf11310 in DB::InterpreterSelectQuery::InterpreterSelectQuery(std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectQuery.cpp:160:7
#26 0x2e1923a0 in std::__1::__unique_if<DB::InterpreterSelectQuery>::__unique_single std::__1::make_unique<DB::InterpreterSelectQuery, std::__1::shared_ptr<DB::IAST> const&, DB::Context&, DB::SelectQueryOptions&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&>(std::__1::shared_ptr<DB::IAST> const&, DB::Context&, DB::SelectQueryOptions&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) obj-x86_64-linux-gnu/../contrib/libcxx/include/memory:2068:32
#27 0x2e1923a0 in DB::InterpreterSelectWithUnionQuery::buildCurrentChildInterpreter(std::__1::shared_ptr<DB::IAST> const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectWithUnionQuery.cpp:211:16
#28 0x2e18d439 in DB::InterpreterSelectWithUnionQuery::InterpreterSelectWithUnionQuery(std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectWithUnionQuery.cpp:133:13
#29 0x2cdfad56 in std::__1::__unique_if<DB::InterpreterSelectWithUnionQuery>::__unique_single std::__1::make_unique<DB::InterpreterSelectWithUnionQuery, std::__1::shared_ptr<DB::IAST>&, DB::Context&, DB::SelectQueryOptions const&>(std::__1::shared_ptr<DB::IAST>&, DB::Context&, DB::SelectQueryOptions const&) obj-x86_64-linux-gnu/../contrib/libcxx/include/memory:2068:32
#30 0x2cdfad56 in DB::InterpreterFactory::get(std::__1::shared_ptr<DB::IAST>&, DB::Context&, DB::SelectQueryOptions const&) obj-x86_64-linux-gnu/../src/Interpreters/InterpreterFactory.cpp:110:16
#31 0x2e89d581 in DB::executeQueryImpl(char const*, char const*, DB::Context&, bool, DB::QueryProcessingStage::Enum, bool, DB::ReadBuffer*) obj-x86_64-linux-gnu/../src/Interpreters/executeQuery.cpp:520:28
#32 0x2e8980e0 in DB::executeQuery(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, DB::Context&, bool, DB::QueryProcessingStage::Enum, bool) obj-x86_64-linux-gnu/../src/Interpreters/executeQuery.cpp:908:30
2021.03.26 01:19:40.922144 [ 113 ] {} <Debug> DiskLocal: Reserving 1.27 MiB on disk `default`, having unreserved 1.05 TiB.
#33 0x30a12f02 in DB::TCPHandler::runImpl() obj-x86_64-linux-gnu/../src/Server/TCPHandler.cpp:289:24
#34 0x30a4fe08 in DB::TCPHandler::run() obj-x86_64-linux-gnu/../src/Server/TCPHandler.cpp:1520:9
#35 0x3b59369a in Poco::Net::TCPServerConnection::start() obj-x86_64-linux-gnu/../contrib/poco/Net/src/TCPServerConnection.cpp:43:3
#36 0x3b594c84 in Poco::Net::TCPServerDispatcher::run() obj-x86_64-linux-gnu/../contrib/poco/Net/src/TCPServerDispatcher.cpp:113:19
#37 0x3ba3f525 in Poco::PooledThread::run() obj-x86_64-linux-gnu/../contrib/poco/Foundation/src/ThreadPool.cpp:199:14
#38 0x3ba3a538 in Poco::(anonymous namespace)::RunnableHolder::run() obj-x86_64-linux-gnu/../contrib/poco/Foundation/src/Thread.cpp:55:11
#39 0x3ba3653b in Poco::ThreadImpl::runnableEntry(void*) obj-x86_64-linux-gnu/../contrib/poco/Foundation/src/Thread_POSIX.cpp:345:27
#40 0x7f3c4803c608 in start_thread /build/glibc-eX1tMB/glibc-2.31/nptl/pthread_create.c:477:8
2021.03.26 01:19:40.951022 [ 113 ] {} <Trace> system.query_log (6b661c4f-2eab-40f1-b916-fc2665b7e7dc): Renaming temporary part tmp_insert_202103_240_240_0 to 202103_240_240_0.
2021.03.26 01:19:40.953110 [ 113 ] {} <Trace> SystemLog (system.query_log): Flushed system log
#41 0x7f3c47f63292 in clone /build/glibc-eX1tMB/glibc-2.31/misc/../sysdeps/unix/sysv/linux/x86_64/clone.S:95
Uninitialized value was stored to memory at
#0 0x902c279 in __msan_memcpy (/workspace/clickhouse+0x902c279)
2021.03.26 01:19:41.018893 [ 183 ] {} <Trace> system.text_log (2e1a0635-a0b8-492b-9c80-2ba208e22ae3): Found 7 old parts to remove.
2021.03.26 01:19:41.019009 [ 183 ] {} <Debug> system.text_log (2e1a0635-a0b8-492b-9c80-2ba208e22ae3): Removing part from filesystem 202103_156_172_3
2021.03.26 01:19:41.020521 [ 183 ] {} <Debug> system.text_log (2e1a0635-a0b8-492b-9c80-2ba208e22ae3): Removing part from filesystem 202103_173_173_0
2021.03.26 01:19:41.020843 [ 183 ] {} <Debug> system.text_log (2e1a0635-a0b8-492b-9c80-2ba208e22ae3): Removing part from filesystem 202103_174_174_0
2021.03.26 01:19:41.021118 [ 183 ] {} <Debug> system.text_log (2e1a0635-a0b8-492b-9c80-2ba208e22ae3): Removing part from filesystem 202103_175_175_0
2021.03.26 01:19:41.021403 [ 183 ] {} <Debug> system.text_log (2e1a0635-a0b8-492b-9c80-2ba208e22ae3): Removing part from filesystem 202103_176_176_0
2021.03.26 01:19:41.021681 [ 183 ] {} <Debug> system.text_log (2e1a0635-a0b8-492b-9c80-2ba208e22ae3): Removing part from filesystem 202103_177_177_0
2021.03.26 01:19:41.021958 [ 183 ] {} <Debug> system.text_log (2e1a0635-a0b8-492b-9c80-2ba208e22ae3): Removing part from filesystem 202103_178_178_0
#1 0x2eed2a1e in void DB::PODArray<wide::integer<256ul, unsigned int>, 4096ul, Allocator<false, false>, 15ul, 16ul>::push_back<wide::integer<256ul, unsigned int> >(wide::integer<256ul, unsigned int>&&) obj-x86_64-linux-gnu/../src/Common/PODArray.h:437:23
#2 0x2eed2a1e in DB::ColumnVector<wide::integer<256ul, unsigned int> >::insert(DB::Field const&) obj-x86_64-linux-gnu/../src/Columns/ColumnVector.h:264:14
#3 0x2c46ed78 in DB::IDataType::createColumnConst(unsigned long, DB::Field const&) const obj-x86_64-linux-gnu/../src/DataTypes/IDataType.cpp:107:13
#4 0x266f9596 in DB::FunctionRange::executeImpl(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long) const (/workspace/clickhouse+0x266f9596)
#5 0x12ea3cdc in DB::IFunction::executeImplDryRun(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long) const (/workspace/clickhouse+0x12ea3cdc)
#6 0x12ea359c in DB::DefaultExecutable::executeDryRun(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long) const (/workspace/clickhouse+0x12ea359c)
#7 0x13010f45 in DB::ExecutableFunctionAdaptor::executeWithoutLowCardinalityColumns(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const (/workspace/clickhouse+0x13010f45)
#8 0x1300f1d3 in DB::ExecutableFunctionAdaptor::defaultImplementationForConstantArguments(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const (/workspace/clickhouse+0x1300f1d3)
#9 0x13010cc3 in DB::ExecutableFunctionAdaptor::executeWithoutLowCardinalityColumns(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const (/workspace/clickhouse+0x13010cc3)
#10 0x13013383 in DB::ExecutableFunctionAdaptor::execute(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const (/workspace/clickhouse+0x13013383)
#11 0x2c70b05f in DB::ActionsDAG::addFunction(std::__1::shared_ptr<DB::IFunctionOverloadResolver> const&, std::__1::vector<DB::ActionsDAG::Node const*, std::__1::allocator<DB::ActionsDAG::Node const*> >, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >) obj-x86_64-linux-gnu/../src/Interpreters/ActionsDAG.cpp:168:35
#12 0x2d810a1b in DB::ScopeStack::addFunction(std::__1::shared_ptr<DB::IFunctionOverloadResolver> const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.cpp:569:51
#13 0x2d822a9c in DB::ActionsMatcher::Data::addFunction(std::__1::shared_ptr<DB::IFunctionOverloadResolver> const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.h:164:27
#14 0x2d822a9c in DB::ActionsMatcher::visit(DB::ASTFunction const&, std::__1::shared_ptr<DB::IAST> const&, DB::ActionsMatcher::Data&) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.cpp:1049:14
#15 0x2d812852 in DB::ActionsMatcher::visit(std::__1::shared_ptr<DB::IAST> const&, DB::ActionsMatcher::Data&) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.cpp:623:9
#16 0x2d81536a in DB::ActionsMatcher::visit(DB::ASTFunction const&, std::__1::shared_ptr<DB::IAST> const&, DB::ActionsMatcher::Data&) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.cpp:779:9
#17 0x2d812852 in DB::ActionsMatcher::visit(std::__1::shared_ptr<DB::IAST> const&, DB::ActionsMatcher::Data&) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.cpp:623:9
#18 0x2d7be52f in DB::InDepthNodeVisitor<DB::ActionsMatcher, true, std::__1::shared_ptr<DB::IAST> const>::visit(std::__1::shared_ptr<DB::IAST> const&) obj-x86_64-linux-gnu/../src/Interpreters/InDepthNodeVisitor.h:34:13
#19 0x2d763cf2 in DB::ExpressionAnalyzer::getRootActionsNoMakeSet(std::__1::shared_ptr<DB::IAST> const&, bool, std::__1::shared_ptr<DB::ActionsDAG>&, bool) obj-x86_64-linux-gnu/../src/Interpreters/ExpressionAnalyzer.cpp:417:48
#20 0x2d75f0bc in DB::ExpressionAnalyzer::analyzeAggregation() obj-x86_64-linux-gnu/../src/Interpreters/ExpressionAnalyzer.cpp:235:21
#21 0x2d7592de in DB::ExpressionAnalyzer::ExpressionAnalyzer(std::__1::shared_ptr<DB::IAST> const&, std::__1::shared_ptr<DB::TreeRewriterResult const> const&, DB::Context const&, unsigned long, bool, std::__1::unordered_map<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, DB::SubqueryForSet, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::allocator<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, DB::SubqueryForSet> > >) obj-x86_64-linux-gnu/../src/Interpreters/ExpressionAnalyzer.cpp:152:5
Uninitialized value was stored to memory at
#0 0x902c279 in __msan_memcpy (/workspace/clickhouse+0x902c279)
#1 0x2eed29a6 in wide::integer<256ul, unsigned int> DB::get<wide::integer<256ul, unsigned int> >(DB::Field const&) obj-x86_64-linux-gnu/../src/Core/Field.h:815:12
#2 0x2eed29a6 in DB::ColumnVector<wide::integer<256ul, unsigned int> >::insert(DB::Field const&) obj-x86_64-linux-gnu/../src/Columns/ColumnVector.h:264:24
#3 0x2c46ed78 in DB::IDataType::createColumnConst(unsigned long, DB::Field const&) const obj-x86_64-linux-gnu/../src/DataTypes/IDataType.cpp:107:13
#4 0x266f9596 in DB::FunctionRange::executeImpl(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long) const (/workspace/clickhouse+0x266f9596)
#5 0x12ea3cdc in DB::IFunction::executeImplDryRun(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long) const (/workspace/clickhouse+0x12ea3cdc)
#6 0x12ea359c in DB::DefaultExecutable::executeDryRun(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long) const (/workspace/clickhouse+0x12ea359c)
#7 0x13010f45 in DB::ExecutableFunctionAdaptor::executeWithoutLowCardinalityColumns(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const (/workspace/clickhouse+0x13010f45)
#8 0x1300f1d3 in DB::ExecutableFunctionAdaptor::defaultImplementationForConstantArguments(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const (/workspace/clickhouse+0x1300f1d3)
#9 0x13010cc3 in DB::ExecutableFunctionAdaptor::executeWithoutLowCardinalityColumns(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const (/workspace/clickhouse+0x13010cc3)
#10 0x13013383 in DB::ExecutableFunctionAdaptor::execute(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const (/workspace/clickhouse+0x13013383)
#11 0x2c70b05f in DB::ActionsDAG::addFunction(std::__1::shared_ptr<DB::IFunctionOverloadResolver> const&, std::__1::vector<DB::ActionsDAG::Node const*, std::__1::allocator<DB::ActionsDAG::Node const*> >, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >) obj-x86_64-linux-gnu/../src/Interpreters/ActionsDAG.cpp:168:35
#12 0x2d810a1b in DB::ScopeStack::addFunction(std::__1::shared_ptr<DB::IFunctionOverloadResolver> const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.cpp:569:51
#13 0x2d822a9c in DB::ActionsMatcher::Data::addFunction(std::__1::shared_ptr<DB::IFunctionOverloadResolver> const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.h:164:27
#14 0x2d822a9c in DB::ActionsMatcher::visit(DB::ASTFunction const&, std::__1::shared_ptr<DB::IAST> const&, DB::ActionsMatcher::Data&) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.cpp:1049:14
#15 0x2d812852 in DB::ActionsMatcher::visit(std::__1::shared_ptr<DB::IAST> const&, DB::ActionsMatcher::Data&) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.cpp:623:9
#16 0x2d81536a in DB::ActionsMatcher::visit(DB::ASTFunction const&, std::__1::shared_ptr<DB::IAST> const&, DB::ActionsMatcher::Data&) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.cpp:779:9
#17 0x2d812852 in DB::ActionsMatcher::visit(std::__1::shared_ptr<DB::IAST> const&, DB::ActionsMatcher::Data&) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.cpp:623:9
#18 0x2d7be52f in DB::InDepthNodeVisitor<DB::ActionsMatcher, true, std::__1::shared_ptr<DB::IAST> const>::visit(std::__1::shared_ptr<DB::IAST> const&) obj-x86_64-linux-gnu/../src/Interpreters/InDepthNodeVisitor.h:34:13
#19 0x2d763cf2 in DB::ExpressionAnalyzer::getRootActionsNoMakeSet(std::__1::shared_ptr<DB::IAST> const&, bool, std::__1::shared_ptr<DB::ActionsDAG>&, bool) obj-x86_64-linux-gnu/../src/Interpreters/ExpressionAnalyzer.cpp:417:48
#20 0x2d75f0bc in DB::ExpressionAnalyzer::analyzeAggregation() obj-x86_64-linux-gnu/../src/Interpreters/ExpressionAnalyzer.cpp:235:21
#21 0x2d7592de in DB::ExpressionAnalyzer::ExpressionAnalyzer(std::__1::shared_ptr<DB::IAST> const&, std::__1::shared_ptr<DB::TreeRewriterResult const> const&, DB::Context const&, unsigned long, bool, std::__1::unordered_map<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, DB::SubqueryForSet, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::allocator<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, DB::SubqueryForSet> > >) obj-x86_64-linux-gnu/../src/Interpreters/ExpressionAnalyzer.cpp:152:5
Uninitialized value was created by an allocation of 'ref.tmp143' in the stack frame of function '_ZNK2DB13FunctionRange11executeImplERKNSt3__16vectorINS_21ColumnWithTypeAndNameENS1_9allocatorIS3_EEEERKNS1_10shared_ptrIKNS_9IDataTypeEEEm'
#0 0x266f7ff0 in DB::FunctionRange::executeImpl(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long) const (/workspace/clickhouse+0x266f7ff0)
SUMMARY: MemorySanitizer: use-of-uninitialized-value obj-x86_64-linux-gnu/../src/Columns/ColumnConst.cpp:41:9 in DB::ColumnConst::ColumnConst(COW<DB::IColumn>::immutable_ptr<DB::IColumn> const&, unsigned long)
Exiting
| https://github.com/ClickHouse/ClickHouse/issues/22157 | https://github.com/ClickHouse/ClickHouse/pull/22387 | f8534acb13ac3650e689c6a15cb70ec6f39b6b04 | 124d9e14ad07daf0cbd6784471aeda27413100a0 | "2021-03-26T10:06:35Z" | c++ | "2021-03-31T06:05:10Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,130 | ["src/Storages/System/StorageSystemZooKeeper.cpp", "src/Storages/System/StorageSystemZooKeeper.h", "tests/config/config.d/zookeeper_write.xml", "tests/config/install.sh", "tests/queries/0_stateless/02311_system_zookeeper_insert.reference", "tests/queries/0_stateless/02311_system_zookeeper_insert.sql", "tests/queries/0_stateless/02311_system_zookeeper_insert_priv.reference", "tests/queries/0_stateless/02311_system_zookeeper_insert_priv.sh"] | Allow writes into system.zookeeper table | **Use case**
Manually modify the contents of ZooKeeper.
Not for normal usage scenarios... mostly for operations engineers.
**Describe the solution you'd like**
Allow INSERT. It should contain only subset of the columns, because some of the columns in `system.zookeeper` table (like numChildren, ctime, etc...) cannot be specified explicitly.
INSERT will perform multiple create operations.
Add a setting to perform set operations (update existing nodes) instead of creating new nodes.
**Additional context**
Also it will be nice to allow "full scan" queries to `system.zookeeper` table to quickly creating dumps.
It can be filtered by condition on prefix of path.
| https://github.com/ClickHouse/ClickHouse/issues/22130 | https://github.com/ClickHouse/ClickHouse/pull/37596 | 37a4d11c6446f626d1105043fe8574d6c7b86cb0 | a893595025e666060cd190099e78d203c2de7442 | "2021-03-25T14:48:45Z" | c++ | "2022-06-02T12:09:07Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,100 | ["docker/server/entrypoint.sh"] | Docker entrypoint script try to chown '.' if log path is not set in config | **Describe the bug**
Docker entrypoint script try to chown '.' if log path is not set in config because LOG_DIR = $(dirname "" || true) returns '.'
**Does it reproduce on recent release?**
21.3.3.14
**How to reproduce**
Remove logger.log or logger.errorlog from config.xml.
**Expected behavior**
The docker container should start without trying to chown '.', which resolves to / since the entrypoint script is located at /.
**Error message and/or stacktrace**
Poco::Exception. Code: 1000, e.code() = 0, e.displayText() = Not found: logger.log (version 21.3.3.14 (official build))
Poco::Exception. Code: 1000, e.code() = 0, e.displayText() = Not found: logger.errorlog (version 21.3.3.14 (official build))
chown: changing ownership of './proc/fs/xfs/xqm': Read-only file system
chown: changing ownership of './proc/fs/xfs/stat': Read-only file system
chown: changing ownership of './proc/fs/xfs/xqmstat': Read-only file system
chown: changing ownership of './proc/fs/xfs': Read-only file system
chown: changing ownership of './proc/fs/cifs/Stats': Read-only file system
chown: changing ownership of './proc/fs/cifs/cifsFYI': Read-only file system
**Additional context**
I believe this bug was introduced by https://github.com/ClickHouse/ClickHouse/pull/18954 where the $LOG_PATH is surrounded with double quotes (""). | https://github.com/ClickHouse/ClickHouse/issues/22100 | https://github.com/ClickHouse/ClickHouse/pull/22102 | 607d36dd9dc91bd4812b683f6f241414737301ce | 4c67e25152c25ead180512d3157c92f2ad0a7d4f | "2021-03-24T21:04:46Z" | c++ | "2021-03-26T19:19:12Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,093 | ["src/Functions/bar.cpp", "tests/queries/0_stateless/01774_bar_with_illegal_value.reference", "tests/queries/0_stateless/01774_bar_with_illegal_value.sql"] | src/Common/UnicodeBar.cpp:31 -nan is outside the range of representable values of type 'unsigned long' | ```sql
SELECT greatCircleAngle(1048575, 257, -9223372036854775808, 1048576) - NULL, bar(7, -inf, 1024)
```
https://clickhouse-test-reports.s3.yandex.net/21889/5de2b8512f4260964413448e8099c6ff5cc23881/fuzzer_ubsan/report.html#fail1
```
2021.03.23 04:33:11.673801 [ 176 ] {a0a4476b-33dd-419b-bbc3-3d2cc08b3ea8} <Debug> executeQuery: (from [::1]:39990, using production parser) SELECT greatCircleAngle(1048575, 257, -9223372036854775808, 1048576) - NULL, bar(7, -inf, 1024)
../src/Common/UnicodeBar.cpp:31:16: runtime error: -nan is outside the range of representable values of type 'unsigned long'
#0 0xea2b1a9 in UnicodeBar::getWidthInBytes(double) obj-x86_64-linux-gnu/../src/Common/UnicodeBar.cpp:31:16
#1 0x16c022dd in DB::(anonymous namespace)::FunctionBar::executeImpl(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long) const (/workspace/clickhouse+0x16c022dd)
#2 0x12542aa4 in DB::IFunction::executeImplDryRun(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long) const (/workspace/clickhouse+0x12542aa4)
#3 0x12547e86 in DB::DefaultExecutable::executeDryRun(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long) const (/workspace/clickhouse+0x12547e86)
#4 0x12fee2aa in DB::ExecutableFunctionAdaptor::executeWithoutLowCardinalityColumns(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const (/workspace/clickhouse+0x12fee2aa)
#5 0x12fed904 in DB::ExecutableFunctionAdaptor::defaultImplementationForConstantArguments(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const (/workspace/clickhouse+0x12fed904)
#6 0x12fee134 in DB::ExecutableFunctionAdaptor::executeWithoutLowCardinalityColumns(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const (/workspace/clickhouse+0x12fee134)
#7 0x12fef2ad in DB::ExecutableFunctionAdaptor::execute(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const (/workspace/clickhouse+0x12fef2ad)
#8 0x1a0bfff5 in DB::ActionsDAG::addFunction(std::__1::shared_ptr<DB::IFunctionOverloadResolver> const&, std::__1::vector<DB::ActionsDAG::Node const*, std::__1::allocator<DB::ActionsDAG::Node const*> >, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >) obj-x86_64-linux-gnu/../src/Interpreters/ActionsDAG.cpp:168:35
#9 0x1a5f1d43 in DB::ScopeStack::addFunction(std::__1::shared_ptr<DB::IFunctionOverloadResolver> const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.cpp:569:51
#10 0x1a603f62 in DB::ActionsMatcher::Data::addFunction(std::__1::shared_ptr<DB::IFunctionOverloadResolver> const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.h:164:27
#11 0x1a5fd0ad in DB::ActionsMatcher::visit(DB::ASTFunction const&, std::__1::shared_ptr<DB::IAST> const&, DB::ActionsMatcher::Data&) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.cpp:1049:14
#12 0x1a60002f in DB::ActionsMatcher::visit(DB::ASTExpressionList&, std::__1::shared_ptr<DB::IAST> const&, DB::ActionsMatcher::Data&) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.cpp
#13 0x1a5d6521 in DB::InDepthNodeVisitor<DB::ActionsMatcher, true, std::__1::shared_ptr<DB::IAST> const>::visit(std::__1::shared_ptr<DB::IAST> const&) obj-x86_64-linux-gnu/../src/Interpreters/InDepthNodeVisitor.h:34:13
#14 0x1a5c343f in DB::ExpressionAnalyzer::getRootActions(std::__1::shared_ptr<DB::IAST> const&, bool, std::__1::shared_ptr<DB::ActionsDAG>&, bool) obj-x86_64-linux-gnu/../src/Interpreters/ExpressionAnalyzer.cpp:406:48
#15 0x1a5cc227 in DB::SelectQueryExpressionAnalyzer::appendSelect(DB::ExpressionActionsChain&, bool) obj-x86_64-linux-gnu/../src/Interpreters/ExpressionAnalyzer.cpp:1119:5
#16 0x1a5d0862 in DB::ExpressionAnalysisResult::ExpressionAnalysisResult(DB::SelectQueryExpressionAnalyzer&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&, bool, bool, bool, std::__1::shared_ptr<DB::FilterDAGInfo> const&, DB::Block const&) obj-x86_64-linux-gnu/../src/Interpreters/ExpressionAnalyzer.cpp:1517:24
#17 0x1a33c834 in DB::InterpreterSelectQuery::getSampleBlockImpl() obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectQuery.cpp:596:23
#18 0x1a33384f in DB::InterpreterSelectQuery::InterpreterSelectQuery(std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, std::__1::shared_ptr<DB::IBlockInputStream> const&, std::__1::optional<DB::Pipe>, std::__1::shared_ptr<DB::IStorage> const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&)::$_2::operator()(bool) const obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectQuery.cpp:475:25
#19 0x1a32e458 in DB::InterpreterSelectQuery::InterpreterSelectQuery(std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, std::__1::shared_ptr<DB::IBlockInputStream> const&, std::__1::optional<DB::Pipe>, std::__1::shared_ptr<DB::IStorage> const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&) obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectQuery.cpp:478:5
#20 0x1a32bfc9 in DB::InterpreterSelectQuery::InterpreterSelectQuery(std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectQuery.cpp:160:7
#21 0x1a8603a7 in std::__1::__unique_if<DB::InterpreterSelectQuery>::__unique_single std::__1::make_unique<DB::InterpreterSelectQuery, std::__1::shared_ptr<DB::IAST> const&, DB::Context&, DB::SelectQueryOptions&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&>(std::__1::shared_ptr<DB::IAST> const&, DB::Context&, DB::SelectQueryOptions&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) obj-x86_64-linux-gnu/../contrib/libcxx/include/memory:2068:32
#22 0x1a85dd23 in DB::InterpreterSelectWithUnionQuery::buildCurrentChildInterpreter(std::__1::shared_ptr<DB::IAST> const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectWithUnionQuery.cpp:211:16
#23 0x1a85c259 in DB::InterpreterSelectWithUnionQuery::InterpreterSelectWithUnionQuery(std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectWithUnionQuery.cpp:133:13
#24 0x1a2c9de5 in std::__1::__unique_if<DB::InterpreterSelectWithUnionQuery>::__unique_single std::__1::make_unique<DB::InterpreterSelectWithUnionQuery, std::__1::shared_ptr<DB::IAST>&, DB::Context&, DB::SelectQueryOptions const&>(std::__1::shared_ptr<DB::IAST>&, DB::Context&, DB::SelectQueryOptions const&) obj-x86_64-linux-gnu/../contrib/libcxx/include/memory:2068:32
#25 0x1a2c893a in DB::InterpreterFactory::get(std::__1::shared_ptr<DB::IAST>&, DB::Context&, DB::SelectQueryOptions const&) obj-x86_64-linux-gnu/../src/Interpreters/InterpreterFactory.cpp:110:16
#26 0x1aaa1c89 in DB::executeQueryImpl(char const*, char const*, DB::Context&, bool, DB::QueryProcessingStage::Enum, bool, DB::ReadBuffer*) obj-x86_64-linux-gnu/../src/Interpreters/executeQuery.cpp:520:28
#27 0x1aaa0ad4 in DB::executeQuery(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, DB::Context&, bool, DB::QueryProcessingStage::Enum, bool) obj-x86_64-linux-gnu/../src/Interpreters/executeQuery.cpp:908:30
#28 0x1b531d0a in DB::TCPHandler::runImpl() obj-x86_64-linux-gnu/../src/Server/TCPHandler.cpp:289:24
#29 0x1b54ba9c in DB::TCPHandler::run() obj-x86_64-linux-gnu/../src/Server/TCPHandler.cpp:1520:9
#30 0x1c47aa0b in Poco::Net::TCPServerConnection::start() obj-x86_64-linux-gnu/../contrib/poco/Net/src/TCPServerConnection.cpp:43:3
#31 0x1c47ae62 in Poco::Net::TCPServerDispatcher::run() obj-x86_64-linux-gnu/../contrib/poco/Net/src/TCPServerDispatcher.cpp:113:19
#32 0x1c5584a9 in Poco::PooledThread::run() obj-x86_64-linux-gnu/../contrib/poco/Foundation/src/ThreadPool.cpp:199:14
#33 0x1c5562ab in Poco::ThreadImpl::runnableEntry(void*) obj-x86_64-linux-gnu/../contrib/poco/Foundation/src/Thread_POSIX.cpp:345:27
#34 0x7fb758506608 in start_thread /build/glibc-eX1tMB/glibc-2.31/nptl/pthread_create.c:477:8
#35 0x7fb75842d292 in clone /build/glibc-eX1tMB/glibc-2.31/misc/../sysdeps/unix/sysv/linux/x86_64/clone.S:95
SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior ../src/Common/UnicodeBar.cpp:31:16 in
2021.03.23 04:33:12.829860 [ 42 ] {} <Trace> BaseDaemon: Received signal -3
2021.03.23 04:33:12.830531 [ 178 ] {} <Fatal> BaseDaemon: ########################################
2021.03.23 04:33:12.830693 [ 178 ] {} <Fatal> BaseDaemon: (version 21.4.1.6316, build id: AEECA1341A9DFB8420DC6FBFE9D99C901B50D217) (from thread 176) (query_id: a0a4476b-33dd-419b-bbc3-3d2cc08b3ea8) Received signal Unknown signal (-3)
2021.03.23 04:33:12.830733 [ 178 ] {} <Fatal> BaseDaemon: Sanitizer trap.
2021.03.23 04:33:12.830822 [ 178 ] {} <Fatal> BaseDaemon: Stack trace: 0xe8ff0b5 0xeb2e4d6 0xe8c2c16 0xe8d06af 0xea2b1aa 0x16c022de 0x12542aa5 0x12547e87 0x12fee2ab 0x12fed905 0x12fee135 0x12fef2ae 0x1a0bfff6 0x1a5f1d44 0x1a603f63 0x1a5fd0ae 0x1a600030 0x1a5d6522 0x1a5c3440 0x1a5cc228 0x1a5d0863 0x1a33c835 0x1a333850 0x1a32e459 0x1a32bfca 0x1a8603a8 0x1a85dd24 0x1a85c25a 0x1a2c9de6 0x1a2c893b 0x1aaa1c8a 0x1aaa0ad5
2021.03.23 04:33:12.847614 [ 178 ] {} <Fatal> BaseDaemon: 0.1. inlined from ./obj-x86_64-linux-gnu/../src/Common/StackTrace.cpp:298: StackTrace::tryCapture()
2021.03.23 04:33:12.847643 [ 178 ] {} <Fatal> BaseDaemon: 0. ../src/Common/StackTrace.cpp:259: StackTrace::StackTrace() @ 0xe8ff0b5 in /workspace/clickhouse
2021.03.23 04:33:12.901394 [ 178 ] {} <Fatal> BaseDaemon: 1. ./obj-x86_64-linux-gnu/../base/daemon/BaseDaemon.cpp:381: sanitizerDeathCallback() @ 0xeb2e4d6 in /workspace/clickhouse
2021.03.23 04:33:13.705240 [ 178 ] {} <Fatal> BaseDaemon: 2. __sanitizer::Die() @ 0xe8c2c16 in /workspace/clickhouse
2021.03.23 04:33:14.503858 [ 178 ] {} <Fatal> BaseDaemon: 3. ? @ 0xe8d06af in /workspace/clickhouse
2021.03.23 04:33:14.506068 [ 178 ] {} <Fatal> BaseDaemon: 4. ./obj-x86_64-linux-gnu/../src/Common/UnicodeBar.cpp:31: ? @ 0xea2b1aa in /workspace/clickhouse
2021.03.23 04:33:15.302761 [ 178 ] {} <Fatal> BaseDaemon: 5. DB::(anonymous namespace)::FunctionBar::executeImpl(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long) const @ 0x16c022de in /workspace/clickhouse
2021.03.23 04:33:15.843882 [ 44 ] {} <Trace> NuKeeperTCPHandler: Received heartbeat for session #1
2021.03.23 04:33:16.098229 [ 178 ] {} <Fatal> BaseDaemon: 6. DB::IFunction::executeImplDryRun(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long) const @ 0x12542aa5 in /workspace/clickhouse
2021.03.23 04:33:16.417730 [ 88 ] {} <Trace> SystemLog (system.query_thread_log): Flushing system log, 1314 entries to flush
2021.03.23 04:33:16.425256 [ 88 ] {} <Debug> DiskLocal: Reserving 1.00 MiB on disk `default`, having unreserved 2.20 TiB.
2021.03.23 04:33:16.428249 [ 88 ] {} <Trace> system.query_thread_log (3dc6c240-e593-49ec-b12d-e3c70aa8e1e3): Renaming temporary part tmp_insert_202103_222_222_0 to 202103_222_222_0.
2021.03.23 04:33:16.428465 [ 88 ] {} <Trace> SystemLog (system.query_thread_log): Flushed system log
2021.03.23 04:33:16.894261 [ 178 ] {} <Fatal> BaseDaemon: 7. DB::DefaultExecutable::executeDryRun(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long) const @ 0x12547e87 in /workspace/clickhouse
2021.03.23 04:33:17.595408 [ 93 ] {} <Trace> SystemLog (system.metric_log): Flushing system log, 7 entries to flush
2021.03.23 04:33:17.604777 [ 93 ] {} <Debug> DiskLocal: Reserving 1.00 MiB on disk `default`, having unreserved 2.20 TiB.
2021.03.23 04:33:17.609336 [ 93 ] {} <Trace> system.metric_log (6cbecbb7-4e82-48e9-9799-208203477dcf): Renaming temporary part tmp_insert_202103_263_263_0 to 202103_263_263_0.
2021.03.23 04:33:17.610094 [ 93 ] {} <Trace> SystemLog (system.metric_log): Flushed system log
2021.03.23 04:33:17.690700 [ 178 ] {} <Fatal> BaseDaemon: 8. DB::ExecutableFunctionAdaptor::executeWithoutLowCardinalityColumns(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const @ 0x12fee2ab in /workspace/clickhouse
2021.03.23 04:33:17.822008 [ 92 ] {} <Debug> DiskLocal: Reserving 2.69 MiB on disk `default`, having unreserved 2.20 TiB.
2021.03.23 04:33:17.827337 [ 92 ] {} <Trace> system.text_log (8f0a0548-b276-4e1a-b399-dd7e75d8f268): Renaming temporary part tmp_insert_202103_263_263_0 to 202103_263_263_0.
2021.03.23 04:33:18.359970 [ 87 ] {} <Trace> SystemLog (system.query_log): Flushing system log, 430 entries to flush
2021.03.23 04:33:18.374503 [ 87 ] {} <Debug> DiskLocal: Reserving 1.37 MiB on disk `default`, having unreserved 2.20 TiB.
2021.03.23 04:33:18.378780 [ 87 ] {} <Trace> system.query_log (30207345-07ac-4852-a5d9-b5d4e3444ad9): Renaming temporary part tmp_insert_202103_229_229_0 to 202103_229_229_0.
2021.03.23 04:33:18.379110 [ 87 ] {} <Trace> SystemLog (system.query_log): Flushed system log
2021.03.23 04:33:18.489176 [ 178 ] {} <Fatal> BaseDaemon: 9. DB::ExecutableFunctionAdaptor::defaultImplementationForConstantArguments(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const @ 0x12fed905 in /workspace/clickhouse
2021.03.23 04:33:19.288532 [ 178 ] {} <Fatal> BaseDaemon: 10. DB::ExecutableFunctionAdaptor::executeWithoutLowCardinalityColumns(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const @ 0x12fee135 in /workspace/clickhouse
2021.03.23 04:33:20.092411 [ 178 ] {} <Fatal> BaseDaemon: 11. DB::ExecutableFunctionAdaptor::execute(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const @ 0x12fef2ae in /workspace/clickhouse
2021.03.23 04:33:20.254301 [ 178 ] {} <Fatal> BaseDaemon: 12.1. inlined from ./obj-x86_64-linux-gnu/../contrib/boost/boost/smart_ptr/intrusive_ptr.hpp:194: boost::intrusive_ptr<DB::IColumn const>::operator*() const
2021.03.23 04:33:20.254356 [ 178 ] {} <Fatal> BaseDaemon: 12. ../src/Interpreters/ActionsDAG.cpp:171: DB::ActionsDAG::addFunction(std::__1::shared_ptr<DB::IFunctionOverloadResolver> const&, std::__1::vector<DB::ActionsDAG::Node const*, std::__1::allocator<DB::ActionsDAG::Node const*> >, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >) @ 0x1a0bfff6 in /workspace/clickhouse
2021.03.23 04:33:20.341535 [ 178 ] {} <Fatal> BaseDaemon: 13. ./obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.cpp:0: DB::ScopeStack::addFunction(std::__1::shared_ptr<DB::IFunctionOverloadResolver> const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >) @ 0x1a5f1d44 in /workspace/clickhouse
2021.03.23 04:33:20.436159 [ 178 ] {} <Fatal> BaseDaemon: 14.1. inlined from ./obj-x86_64-linux-gnu/../contrib/libcxx/include/string:1444: std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >::__is_long() const
2021.03.23 04:33:20.436186 [ 178 ] {} <Fatal> BaseDaemon: 14.2. inlined from ../contrib/libcxx/include/string:2218: ~basic_string
2021.03.23 04:33:20.436225 [ 178 ] {} <Fatal> BaseDaemon: 14. ../src/Interpreters/ActionsVisitor.h:164: DB::ActionsMatcher::Data::addFunction(std::__1::shared_ptr<DB::IFunctionOverloadResolver> const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >) @ 0x1a603f63 in /workspace/clickhouse
2021.03.23 04:33:20.524902 [ 178 ] {} <Fatal> BaseDaemon: 15.1. inlined from ./obj-x86_64-linux-gnu/../contrib/libcxx/include/string:1444: std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >::__is_long() const
2021.03.23 04:33:20.524928 [ 178 ] {} <Fatal> BaseDaemon: 15.2. inlined from ../contrib/libcxx/include/string:2218: ~basic_string
2021.03.23 04:33:20.524969 [ 178 ] {} <Fatal> BaseDaemon: 15. ../src/Interpreters/ActionsVisitor.cpp:1049: DB::ActionsMatcher::visit(DB::ASTFunction const&, std::__1::shared_ptr<DB::IAST> const&, DB::ActionsMatcher::Data&) @ 0x1a5fd0ae in /workspace/clickhouse
2021.03.23 04:33:20.617513 [ 178 ] {} <Fatal> BaseDaemon: 16. ./obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.cpp:0: DB::ActionsMatcher::visit(DB::ASTExpressionList&, std::__1::shared_ptr<DB::IAST> const&, DB::ActionsMatcher::Data&) @ 0x1a600030 in /workspace/clickhouse
2021.03.23 04:33:20.720126 [ 178 ] {} <Fatal> BaseDaemon: 17. ./obj-x86_64-linux-gnu/../src/Interpreters/InDepthNodeVisitor.h:43: DB::InDepthNodeVisitor<DB::ActionsMatcher, true, std::__1::shared_ptr<DB::IAST> const>::visit(std::__1::shared_ptr<DB::IAST> const&) @ 0x1a5d6522 in /workspace/clickhouse
2021.03.23 04:33:20.810786 [ 97 ] {} <Debug> DNSResolver: Updating DNS cache
2021.03.23 04:33:20.823959 [ 178 ] {} <Fatal> BaseDaemon: 18.1. inlined from ./obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.h:169: DB::ActionsMatcher::Data::getActions()
2021.03.23 04:33:20.823999 [ 178 ] {} <Fatal> BaseDaemon: 18. ../src/Interpreters/ExpressionAnalyzer.cpp:407: DB::ExpressionAnalyzer::getRootActions(std::__1::shared_ptr<DB::IAST> const&, bool, std::__1::shared_ptr<DB::ActionsDAG>&, bool) @ 0x1a5c3440 in /workspace/clickhouse
2021.03.23 04:33:20.929503 [ 97 ] {} <Information> DNSResolver: Cached hosts not found: 127.0.0.{1οΏ½2}, 127.0.οΏ½.1, 127.οΏ½.0.2, 127.0.οΏ½.2, 127.οΏ½.0.1, 127.0.0.{1οΏ½.2}, 127.0.0.οΏ½1..2}, 127.0.0.1127.0.0.1127.0.0.1127.0.0.1, οΏ½27.0.0.3, 127.0.0.1127.0.0.1127.0.0.1127.0.0.2, 127.0.0.2127.0.0.2127.0.0.2127.0.0.3, 127.0.0.1127.0.0.1127.0.0.2127.0.0.2, 127.0.0.2127.0.0.2127.0.0.3127.0.0.3, 127.0.0.2127.0.0.1, 127.0.0.1127.0.0.2127.0.0.1127.0.0.1, 127.0.0.2127.0.0.1127.0.0.1127.0.0.1, 127.0.0.1127.0.0.2127.0.0.1127.0.0.2, 127.0.0.3127.0.0.2127.0.0.2127.0.0.2, 127.0.0.3127.0.0.3, 127.0.0.1127.0.0.2127.0.0.2127.0.0.2, 127.0.0.2127.0.0.2127.0.0.1127.0.0.1, 127.0.0.2127.0.0.2127.0.0.1127.0.0.2, 127.0.0.1127.0.0.2, οΏ½27.0.0.2, 127.0.0.1127.0.0.1127.0.0.2127.0.0.1, 127.0.0.3127.0.0.2127.0.0.2127.0.0.3, 127.0.0.2127.0.0.1127.0.0.2127.0.0.1, 127.0.0.2127.0.0.2127.0.0.2127.0.0.1, 127.0.0.2127.0.0.2, 127.0.0.3127.0.0.2127.0.0.3127.0.0.2, 127.0.0.2127.0.0.3, 127.0.0.2127.0.0.2127.0.0.2127.0.0.2, 127.0.0.1127.0.0.2127.0.0.2127.0.0.1, 127.0.0.2127.0.0.1127.0.0.2127.0.0.2, 127.0.0.3127.0.0.2, 127.0.0.3127.0.0.3127.0.0.3127.0.0.2, 127.0.0.2127.0.0.2127.0.0.3127.0.0.2, 127.0.0.οΏ½, 127.0.0.2127.0.0.1127.0.0.1127.0.0.2, 127.0.0.2127.0.0.3127.0.0.2127.0.0.2, 127.0.0.2127.0.0.3127.0.0.2127.0.0.3, 127.0.0.2127.0.0.3127.0.0.3127.0.0.2, 127.0.0.2127.0.0.3127.0.0.3127.0.0.3, 127.0.0.3127.0.0.2127.0.0.3127.0.0.3, 127.0.0.3127.0.0.3127.0.0.2127.0.0.2, 127.0.0.1127.0.0.1, 127.0.0.3127.0.0.3127.0.0.3127.0.0.3, 127.0.0.3127.0.0.3127.0.0.2127.0.0.3
2021.03.23 04:33:20.929547 [ 97 ] {} <Debug> DNSResolver: Updated DNS cache
2021.03.23 04:33:20.933962 [ 178 ] {} <Fatal> BaseDaemon: 19. ./obj-x86_64-linux-gnu/../src/Interpreters/ExpressionAnalyzer.cpp:0: DB::SelectQueryExpressionAnalyzer::appendSelect(DB::ExpressionActionsChain&, bool) @ 0x1a5cc228 in /workspace/clickhouse
2021.03.23 04:33:21.044311 [ 178 ] {} <Fatal> BaseDaemon: 20. ./obj-x86_64-linux-gnu/../src/Interpreters/ExpressionAnalyzer.cpp:0: DB::ExpressionAnalysisResult::ExpressionAnalysisResult(DB::SelectQueryExpressionAnalyzer&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&, bool, bool, bool, std::__1::shared_ptr<DB::FilterDAGInfo> const&, DB::Block const&) @ 0x1a5d0863 in /workspace/clickhouse
2021.03.23 04:33:21.220389 [ 178 ] {} <Fatal> BaseDaemon: 21. ./obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectQuery.cpp:596: DB::InterpreterSelectQuery::getSampleBlockImpl() @ 0x1a33c835 in /workspace/clickhouse
2021.03.23 04:33:21.395050 [ 178 ] {} <Fatal> BaseDaemon: 22. ./obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectQuery.cpp:475: DB::InterpreterSelectQuery::InterpreterSelectQuery(std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, std::__1::shared_ptr<DB::IBlockInputStream> const&, std::__1::optional<DB::Pipe>, std::__1::shared_ptr<DB::IStorage> const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&)::$_2::operator()(bool) const @ 0x1a333850 in /workspace/clickhouse
2021.03.23 04:33:21.563546 [ 178 ] {} <Fatal> BaseDaemon: 23. ./obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectQuery.cpp:481: DB::InterpreterSelectQuery::InterpreterSelectQuery(std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, std::__1::shared_ptr<DB::IBlockInputStream> const&, std::__1::optional<DB::Pipe>, std::__1::shared_ptr<DB::IStorage> const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&) @ 0x1a32e459 in /workspace/clickhouse
2021.03.23 04:33:21.731336 [ 178 ] {} <Fatal> BaseDaemon: 24. ./obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectQuery.cpp:160: DB::InterpreterSelectQuery::InterpreterSelectQuery(std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) @ 0x1a32bfca in /workspace/clickhouse
2021.03.23 04:33:21.804719 [ 178 ] {} <Fatal> BaseDaemon: 25. ./obj-x86_64-linux-gnu/../contrib/libcxx/include/memory:2068: std::__1::__unique_if<DB::InterpreterSelectQuery>::__unique_single std::__1::make_unique<DB::InterpreterSelectQuery, std::__1::shared_ptr<DB::IAST> const&, DB::Context&, DB::SelectQueryOptions&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&>(std::__1::shared_ptr<DB::IAST> const&, DB::Context&, DB::SelectQueryOptions&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) @ 0x1a8603a8 in /workspace/clickhouse
2021.03.23 04:33:21.871690 [ 178 ] {} <Fatal> BaseDaemon: 26. ./obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectWithUnionQuery.cpp:211: DB::InterpreterSelectWithUnionQuery::buildCurrentChildInterpreter(std::__1::shared_ptr<DB::IAST> const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) @ 0x1a85dd24 in /workspace/clickhouse
2021.03.23 04:33:21.937672 [ 178 ] {} <Fatal> BaseDaemon: 27. ./obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectWithUnionQuery.cpp:133: DB::InterpreterSelectWithUnionQuery::InterpreterSelectWithUnionQuery(std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) @ 0x1a85c25a in /workspace/clickhouse
2021.03.23 04:33:21.998919 [ 178 ] {} <Fatal> BaseDaemon: 28. ./obj-x86_64-linux-gnu/../contrib/libcxx/include/memory:0: std::__1::__unique_if<DB::InterpreterSelectWithUnionQuery>::__unique_single std::__1::make_unique<DB::InterpreterSelectWithUnionQuery, std::__1::shared_ptr<DB::IAST>&, DB::Context&, DB::SelectQueryOptions const&>(std::__1::shared_ptr<DB::IAST>&, DB::Context&, DB::SelectQueryOptions const&) @ 0x1a2c9de6 in /workspace/clickhouse
2021.03.23 04:33:22.059268 [ 178 ] {} <Fatal> BaseDaemon: 29.1. inlined from ./obj-x86_64-linux-gnu/../contrib/libcxx/include/memory:1649: std::__1::unique_ptr<DB::InterpreterSelectWithUnionQuery, std::__1::default_delete<DB::InterpreterSelectWithUnionQuery> >::release()
2021.03.23 04:33:22.059306 [ 178 ] {} <Fatal> BaseDaemon: 29.2. inlined from ../contrib/libcxx/include/memory:1563: unique_ptr<DB::InterpreterSelectWithUnionQuery, std::__1::default_delete<DB::InterpreterSelectWithUnionQuery>, void, void>
2021.03.23 04:33:22.059355 [ 178 ] {} <Fatal> BaseDaemon: 29. ../src/Interpreters/InterpreterFactory.cpp:110: DB::InterpreterFactory::get(std::__1::shared_ptr<DB::IAST>&, DB::Context&, DB::SelectQueryOptions const&) @ 0x1a2c893b in /workspace/clickhouse
2021.03.23 04:33:22.157200 [ 178 ] {} <Fatal> BaseDaemon: 30. ./obj-x86_64-linux-gnu/../src/Interpreters/executeQuery.cpp:520: DB::executeQueryImpl(char const*, char const*, DB::Context&, bool, DB::QueryProcessingStage::Enum, bool, DB::ReadBuffer*) @ 0x1aaa1c8a in /workspace/clickhouse
2021.03.23 04:33:22.259269 [ 178 ] {} <Fatal> BaseDaemon: 31. ./obj-x86_64-linux-gnu/../src/Interpreters/executeQuery.cpp:908: DB::executeQuery(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, DB::Context&, bool, DB::QueryProcessingStage::Enum, bool) @ 0x1aaa0ad5 in /workspace/clickhouse
2021.03.23 04:33:22.462588 [ 178 ] {} <Fatal> BaseDaemon: Calculated checksum of the binary: 799351CC5D5B54DA933C4DA73FD28F72. There is no information about the reference checksum.
``` | https://github.com/ClickHouse/ClickHouse/issues/22093 | https://github.com/ClickHouse/ClickHouse/pull/22114 | ddbd95be2d2ca8acba467c88b73afaba2577b121 | 0e4206052337ce47da91866c96049da688ea55be | "2021-03-24T14:43:07Z" | c++ | "2021-03-25T23:36:02Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,067 | ["src/IO/WriteBufferFromS3.cpp", "src/Server/InterserverIOHTTPHandler.cpp"] | Uncaught DB::Exception: Cannot write to ostream | **Describe the bug**
We have clickhouse-server going down now and then when inserting large amounts of data via clickhouse-client with an uncaught exception: "Terminate called for uncaught exception:#012Code: 24, e.displayText() = DB::Exception: Cannot write to ostream at offset 7937". I see there are several PRs (#20464, #20981, #21305) trying to fix this kind of errors, but it looks like not all corner cases are handled. From the code, `finalize()` will just re-throw any nested exception and it will end up unhandled in the HTTP server.
**Does it reproduce on recent release?**
21.3.2.5
**How to reproduce**
* Which ClickHouse server version to use
21.3.2.5
**Expected behavior**
The error must not be fatal.
**Error message and/or stacktrace**
```
2021.03.24 03:46:09.707694 [ 23124 ] {} <Fatal> BaseDaemon: (version 21.3.2.5, build id: 293C622C5C9ED35A848F4B84070256EB217A812D) (from thread 64876) Terminate called for uncaught exception:#012Code: 24, e.displayText() = DB::Exception: Cannot write to ostream at offset 7937, Stack trace (when copying this message, always include the lines below):#012#0120. DB::WriteBufferFromOStream::nextImpl() @ 0x8a46fc0 in /usr/bin/clickhouse#0121. DB::WriteBufferFromHTTPServerResponse::nextImpl() @ 0xfccb800 in /usr/bin/clickhouse#0122. DB::WriteBufferFromHTTPServerResponse::finalize() @ 0xfccbdf2 in /usr/bin/clickhouse#0123. DB::WriteBufferFromHTTPServerResponse::~WriteBufferFromHTTPServerResponse() @ 0xfccc486 in /usr/bin/clickhouse#0124. DB::InterserverIOHTTPHandler::handleRequest(DB::HTTPServerRequest&, DB::HTTPServerResponse&) @ 0xfc4c32a in /usr/bin/clickhouse#0125. DB::HTTPServerConnection::run() @ 0xfcc460f in /usr/bin/clickhouse#0126. Poco::Net::TCPServerConnection::start() @ 0x1236ec7f in /usr/bin/clickhouse#0127. Poco::Net::TCPServerDispatcher::run() @ 0x12370691 in /usr/bin/clickhouse#0128. Poco::PooledThread::run() @ 0x124a6db9 in /usr/bin/clickhouse#0129. Poco::ThreadImpl::runnableEntry(void*) @ 0x124a2c1a in /usr/bin/clickhouse#01210. start_thread @ 0x7fa3 in /usr/lib/x86_64-linux-gnu/libpthread-2.28.so#01211. clone @ 0xf94cf in /usr/lib/x86_64-linux-gnu/libc-2.28.so#012 (version 21.3.2.5)
2021.03.24 03:46:09.726762 [ 71381 ] {} <Fatal> BaseDaemon: ########################################
2021.03.24 03:46:09.726927 [ 71381 ] {} <Fatal> BaseDaemon: (version 21.3.2.5, build id: 293C622C5C9ED35A848F4B84070256EB217A812D) (from thread 64876) (no query) Received signal Aborted (6)
2021.03.24 03:46:09.726944 [ 71381 ] {} <Fatal> BaseDaemon:
2021.03.24 03:46:09.726965 [ 71381 ] {} <Fatal> BaseDaemon: Stack trace: 0x7fd6225807bb 0x7fd62256b535 0x8b093b8 0x13eb9163 0x13eb910c 0x894cf5b 0xfccc5ed 0xfc4c32a 0xfcc460f 0x1236ec7f 0x12370691 0x124a6db9 0x124a2c1a 0x7fd622711fa3 0x7fd6226424cf
2021.03.24 03:46:09.727074 [ 71381 ] {} <Fatal> BaseDaemon: 1. raise @ 0x377bb in /usr/lib/x86_64-linux-gnu/libc-2.28.so
2021.03.24 03:46:09.727085 [ 71381 ] {} <Fatal> BaseDaemon: 2. abort @ 0x22535 in /usr/lib/x86_64-linux-gnu/libc-2.28.so
2021.03.24 03:46:09.727163 [ 71381 ] {} <Fatal> BaseDaemon: 3. ? @ 0x8b093b8 in /usr/bin/clickhouse
2021.03.24 03:46:09.727246 [ 71381 ] {} <Fatal> BaseDaemon: 4. ? @ 0x13eb9163 in ?
2021.03.24 03:46:09.727278 [ 71381 ] {} <Fatal> BaseDaemon: 5. std::terminate() @ 0x13eb910c in ?
2021.03.24 03:46:09.727358 [ 71381 ] {} <Fatal> BaseDaemon: 6. ? @ 0x894cf5b in /usr/bin/clickhouse
2021.03.24 03:46:09.727382 [ 71381 ] {} <Fatal> BaseDaemon: 7. DB::WriteBufferFromHTTPServerResponse::~WriteBufferFromHTTPServerResponse() @ 0xfccc5ed in /usr/bin/clickhouse
2021.03.24 03:46:09.727406 [ 71381 ] {} <Fatal> BaseDaemon: 8. DB::InterserverIOHTTPHandler::handleRequest(DB::HTTPServerRequest&, DB::HTTPServerResponse&) @ 0xfc4c32a in /usr/bin/clickhouse
2021.03.24 03:46:09.727432 [ 71381 ] {} <Fatal> BaseDaemon: 9. DB::HTTPServerConnection::run() @ 0xfcc460f in /usr/bin/clickhouse
2021.03.24 03:46:09.727448 [ 71381 ] {} <Fatal> BaseDaemon: 10. Poco::Net::TCPServerConnection::start() @ 0x1236ec7f in /usr/bin/clickhouse
2021.03.24 03:46:09.727457 [ 71381 ] {} <Fatal> BaseDaemon: 11. Poco::Net::TCPServerDispatcher::run() @ 0x12370691 in /usr/bin/clickhouse
2021.03.24 03:46:09.727469 [ 71381 ] {} <Fatal> BaseDaemon: 12. Poco::PooledThread::run() @ 0x124a6db9 in /usr/bin/clickhouse
2021.03.24 03:46:09.727479 [ 71381 ] {} <Fatal> BaseDaemon: 13. Poco::ThreadImpl::runnableEntry(void*) @ 0x124a2c1a in /usr/bin/clickhouse
2021.03.24 03:46:09.727497 [ 71381 ] {} <Fatal> BaseDaemon: 14. start_thread @ 0x7fa3 in /usr/lib/x86_64-linux-gnu/libpthread-2.28.so
2021.03.24 03:46:09.727508 [ 71381 ] {} <Fatal> BaseDaemon: 15. clone @ 0xf94cf in /usr/lib/x86_64-linux-gnu/libc-2.28.so
2021.03.24 03:46:09.840498 [ 71381 ] {} <Fatal> BaseDaemon: Calculated checksum of the binary: DCFE6F75B6E72B76D731FF6621C84A85. There is no information about the reference checksum.
``` | https://github.com/ClickHouse/ClickHouse/issues/22067 | https://github.com/ClickHouse/ClickHouse/pull/22146 | a455762933559d75bad92c1fa9318b203ec2ea9b | ac53d30e53e06ae617a87c732c07df3c6cd54df2 | "2021-03-24T04:30:25Z" | c++ | "2021-03-26T14:23:09Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,028 | ["src/Functions/connectionID.cpp", "src/Functions/version.cpp", "tests/queries/0_stateless/01773_case_sensitive_version.reference", "tests/queries/0_stateless/01773_case_sensitive_version.sql", "tests/queries/0_stateless/01774_case_sensitive_connection_id.reference", "tests/queries/0_stateless/01774_case_sensitive_connection_id.sql"] | why connection_id() and version() aliases exists, but CONNECTION_ID() and VERSION() is not? ;) | **Describe the bug**
According to https://jira.percona.com/browse/PT-1945 and https://github.com/ClickHouse/ClickHouse/pull/21367
**Does it reproduce on a recent release?**
yep
**How to reproduce**
- define `mysql_port`
- run following SQL queries via MySQL client
```
mysql> SELECT DATABASE(), CONNECTION_ID(), VERSION()/*!50038 , @@hostname*/;
ERROR 46 (00000): Code: 46, e.displayText() = DB::Exception: Unknown function CONNECTION_ID. Maybe you meant: ['connection_id','connectionID']: While processing DATABASE(), CONNECTION_ID(), VERSION() (version 21.3.2.5 (official build))
mysql> SELECT DATABASE(), connection_id(), VERSION()/*!50038 , @@hostname*/;
ERROR 46 (00000): Code: 46, e.displayText() = DB::Exception: Unknown function VERSION. Maybe you meant: ['version']: While processing DATABASE(), connection_id(), VERSION() (version 21.3.2.5 (official build))
mysql> SELECT DATABASE(), connection_id(), version()/*!50038 , @@hostname*/;
+------------+-----------------+-----------+
| DATABASE() | connection_id() | version() |
+------------+-----------------+-----------+
| default | 0 | 21.3.3.14 |
+------------+-----------------+-----------+
```
**Expected behavior**
VERSION() and CONNECTION_ID() aliases should work ;)
| https://github.com/ClickHouse/ClickHouse/issues/22028 | https://github.com/ClickHouse/ClickHouse/pull/22042 | 103de0838b4290dc0fe2435f3af5c48e1b5a6db3 | bb925e16bf727be2b61df23261f987672800f0c0 | "2021-03-23T13:00:57Z" | c++ | "2021-03-29T18:02:24Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,017 | ["src/Interpreters/convertFieldToType.cpp", "tests/queries/0_stateless/01774_tuple_null_in.reference", "tests/queries/0_stateless/01774_tuple_null_in.sql"] | Optimization for nullable tuple create invalid ClickHouse filtering | **Describe the bug**
Using a `NULL` tuple as a left operand with a chained or operands produce an invalid ClickHouse filtering.
**Does it reproduce on recent release?**
Can be reproduced with `21.2.2.8`
**How to reproduce**
```
SELECT (NULL, NULL) = (8, 0) OR (NULL, NULL) = (3, 2) OR (NULL, NULL) = (0, 0) OR (NULL, NULL) = (3, 1)
Received exception from server (version 21.2.2):
Code: 53. DB::Exception: Received from 127.0.0.1:10000. DB::Exception: Type mismatch in IN or VALUES section. Expected: Nothing. Got: UInt64: While processing (NULL, NULL) IN ((0, 0), (3, 1), (3, 2), (8, 0)).
```
**Expected behavior**
It should return `NULL`, or at least the same output as `equals(tuple(NULL, NULL), tuple(3, 2))` | https://github.com/ClickHouse/ClickHouse/issues/22017 | https://github.com/ClickHouse/ClickHouse/pull/22063 | f58d470dd633099f1b7c602991d0d699aba72f68 | 37a4f3ab3aead4cbfe2963ecd1911f999c60db9b | "2021-03-23T07:53:23Z" | c++ | "2021-03-25T12:59:41Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 22,008 | ["src/DataStreams/NativeBlockOutputStream.cpp", "src/DataStreams/NativeBlockOutputStream.h", "src/Processors/Formats/Impl/ParallelFormattingOutputFormat.cpp", "src/Processors/Formats/Impl/ParallelFormattingOutputFormat.h", "tests/queries/0_stateless/01783_parallel_formatting_memory.reference", "tests/queries/0_stateless/01783_parallel_formatting_memory.sh"] | Memory limit sometimes doesn't work with TSan | (you don't have to strictly follow this form)
**Describe the bug**
The following query leads to OOM if server was built with thread sanitizer.
```sql
SELECT range(65535) FROM system.one ARRAY JOIN range(65536) AS number
| https://github.com/ClickHouse/ClickHouse/issues/22008 | https://github.com/ClickHouse/ClickHouse/pull/22425 | 85fbb7eccf4f01376a0169ebee99211ecfeba22d | e3aa47c525e39c1861f3fa2f5f70ff97b620a0e6 | "2021-03-22T21:15:37Z" | c++ | "2021-04-01T13:23:48Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,991 | ["tests/queries/0_stateless/01765_tehran_dst.reference", "tests/queries/0_stateless/01765_tehran_dst.sql"] | Tehran wrong TZ info (+0430) for summer DST | export TZ=Asia/Tehran
```
$ date
Mon 22 Mar 2021 08:46:47 PM +0430
SELECT toTimeZone(now(), 'Asia/Tehran')
ββtoTimeZone(now(), 'Asia/Tehran')ββ
β 2021-03-22 19:47:04 β
ββββββββββββββββββββββββββββββββββββ
```
related https://github.com/ClickHouse/ClickHouse/issues/13845 | https://github.com/ClickHouse/ClickHouse/issues/21991 | https://github.com/ClickHouse/ClickHouse/pull/21995 | 7a48ce6b794b1259898d919b24ae0abbc25cac06 | 7c0dba1b0ce30ff216f82fb1fa87b1d11b88b5d6 | "2021-03-22T16:17:39Z" | c++ | "2021-03-23T17:04:13Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,935 | ["src/Dictionaries/HashedDictionary.cpp"] | Increased hashed dictionary RAM x4 usage after upgrade CH to 21.3 | After upgrade CH from 20.8 to 21.3 I noticed RAM used by dictionary with `hashed` layout was increased exactly in **4** times.
OS: Ubuntu 20.04
Processor: AMD EPYC 7502P 32-Core Processor
RAM: 252 GB
`<dictionaries_lazy_load>false</dictionaries_lazy_load>
`
In 20.8 release CH was using less memory for dictionaries with `hashed` layout.
The problem was not detected for dictionaries with `ComplexKeyHashed` layout. But they have a small amount of data (up to 500 MB).
After server restart with 20.8 version memory usage is increasing up to 30 GB (all dictionaries RAM usage) step by step during dictionaries loading.
After server restart with 21.3 version memory usage is increasing up to 112 GB almost immediately and then decreasing to 91 GB.
Maybe it's a consequence after #18236
20.8 version dictionary
```
ββstatusββ¬βtypeββββ¬βkeyβββββ¬βattribute.typesββ¬βelement_countββ¬βformatReadableSize(bytes_allocated)ββ
β LOADED β Hashed β UInt64 β ['Float64'] β 428492347 β 16.00 GiB β
ββββββββββ΄βββββββββ΄βββββββββ΄ββββββββββββββββββ΄ββββββββββββββββ΄ββββββββββββββββββββββββββββββββββββββ
```
21.3 version dictionary
```
ββstatusββ¬βtypeββββ¬βkeyβββββ¬βattribute.typesββ¬βelement_countββ¬βformatReadableSize(bytes_allocated)ββ
β LOADED β Hashed β UInt64 β ['Float64'] β 428492347 β 64.00 GiB β
ββββββββββ΄βββββββββ΄βββββββββ΄ββββββββββββββββββ΄ββββββββββββββββ΄ββββββββββββββββββββββββββββββββββββββ
```
Dictionaries with the same scheme but another amount of data also have this problem. | https://github.com/ClickHouse/ClickHouse/issues/21935 | https://github.com/ClickHouse/ClickHouse/pull/21948 | 6ce7acb5a9ce361dc4acda55c871330d98b76c58 | af25805a7017223c9f2b4c3f289ee95484ef92fb | "2021-03-19T19:20:56Z" | c++ | "2021-03-22T11:11:19Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,911 | ["programs/copier/ClusterCopier.cpp", "programs/copier/ClusterCopier.h", "programs/copier/TaskCluster.h"] | some copier work needs to be improved | - some copier work needs to be improved
1. clickhouse create destionation table just once if success
2. support settings_push.replication_alter_partitions_sync =1 at attach partition
3. ... | https://github.com/ClickHouse/ClickHouse/issues/21911 | https://github.com/ClickHouse/ClickHouse/pull/21912 | 0696ed390d100611d5569e7213e0c157540c78e7 | 18dc213cee72bb95150ed6e74de996dd131a00eb | "2021-03-19T12:55:26Z" | c++ | "2021-03-30T11:42:00Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,907 | ["src/IO/HTTPChunkedReadBuffer.cpp", "src/IO/HTTPChunkedReadBuffer.h", "src/Server/HTTP/HTTPServerRequest.cpp", "tests/queries/0_stateless/01783_http_chunk_size.reference", "tests/queries/0_stateless/01783_http_chunk_size.sh", "tests/queries/skip_list.json"] | JDBC driver / specific HTTP clients: Chunk size is too large error when executing an "INSERT INTO" with HTTP client compression | I recently doing some tests for updating from clickhouse 20.3 to 21.3.2.5.
With this new build, when I am executing large insertion over the HTTP connection, with compression activated on the client side
Like this query
POST /?query=INSERT+INTO+%60avc%60.%60topconversationdetails%60+FORMAT+RowBinary&database=avc&compress=1&decompress=1 HTTP/1.1
Where data are inside the content on the HTTP request in compressed row binary format
I sometimes see this errors/stack trace in the clickhouse log file :
```
2021.03.19 11:54:42.764099 [ 41063 ] {eba46f57-0491-4ffb-b571-ed9d1618da75} <Error> DynamicQueryHandler: Code: 307, e.displayText() = DB::Exception: Chunk size is too large, Stack trace (when copying this message, always include the lines below):
0. DB::HTTPChunkedReadBuffer::readChunkHeader() @ 0xf8d5e5b in /opt/InfoVista/5ViewSDM/bin/clickhouse
1. DB::HTTPChunkedReadBuffer::nextImpl() @ 0xf8d616b in /opt/InfoVista/5ViewSDM/bin/clickhouse
2. DB::wrapReadBufferReference(DB::ReadBuffer&)::ReadBufferWrapper::nextImpl() @ 0xe7183fc in /opt/InfoVista/5ViewSDM/bin/clickhouse
3. DB::CompressedReadBufferBase::readCompressedData(unsigned long&, unsigned long&, bool) @ 0xe7d88cc in /opt/InfoVista/5ViewSDM/bin/clickhouse
4. DB::CompressedReadBuffer::nextImpl() @ 0xe7d83e7 in /opt/InfoVista/5ViewSDM/bin/clickhouse
5. DB::ConcatReadBuffer::nextImpl() @ 0xe966e1e in /opt/InfoVista/5ViewSDM/bin/clickhouse
6. DB::LimitReadBuffer::nextImpl() @ 0x86a7fcc in /opt/InfoVista/5ViewSDM/bin/clickhouse
7. DB::executeQuery(DB::ReadBuffer&, DB::WriteBuffer&, bool, DB::Context&, std::__1::function<void (std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&)>) @ 0xf1306cb in /opt/InfoVista/5ViewSDM/bin/clickhouse
8. DB::HTTPHandler::processQuery(DB::Context&, DB::HTTPServerRequest&, DB::HTMLForm&, DB::HTTPServerResponse&, DB::HTTPHandler::Output&, std::__1::optional<DB::CurrentThread::QueryScope>&) @ 0xf84675a in /opt/InfoVista/5ViewSDM/bin/clickhouse
9. DB::HTTPHandler::handleRequest(DB::HTTPServerRequest&, DB::HTTPServerResponse&) @ 0xf84a8ee in /opt/InfoVista/5ViewSDM/bin/clickhouse
10. DB::HTTPServerConnection::run() @ 0xf8d35ff in /opt/InfoVista/5ViewSDM/bin/clickhouse
11. Poco::Net::TCPServerConnection::start() @ 0x11f7ccbf in /opt/InfoVista/5ViewSDM/bin/clickhouse
12. Poco::Net::TCPServerDispatcher::run() @ 0x11f7e6d1 in /opt/InfoVista/5ViewSDM/bin/clickhouse
13. Poco::PooledThread::run() @ 0x120b4df9 in /opt/InfoVista/5ViewSDM/bin/clickhouse
14. Poco::ThreadImpl::runnableEntry(void*) @ 0x120b0c5a in /opt/InfoVista/5ViewSDM/bin/clickhouse
15. start_thread @ 0x7dd5 in /usr/lib64/libpthread-2.17.so
16. __clone @ 0xfdead in /usr/lib64/libc-2.17.so
(version 21.3.2.5 (official build))
2021.03.19 11:54:42.764302 [ 41063 ] {eba46f57-0491-4ffb-b571-ed9d1618da75} <Error> DynamicQueryHandler: Cannot send exception to client: Code: 246, e.displayText() = DB::Exception: Unexpected data instead of HTTP chunk header, Stack trace (when copying this message, always include the lines below):
0. DB::HTTPChunkedReadBuffer::readChunkHeader() @ 0xf8d5e02 in /opt/InfoVista/5ViewSDM/bin/clickhouse
1. DB::HTTPChunkedReadBuffer::nextImpl() @ 0xf8d616b in /opt/InfoVista/5ViewSDM/bin/clickhouse
2. DB::HTTPHandler::trySendExceptionToClient(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, int, DB::HTTPServerRequest&, DB::HTTPServerResponse&, DB::HTTPHandler::Output&) @ 0xf849ca2 in /opt/InfoVista/5ViewSDM/bin/clickhouse
3. DB::HTTPHandler::handleRequest(DB::HTTPServerRequest&, DB::HTTPServerResponse&) @ 0xf84b015 in /opt/InfoVista/5ViewSDM/bin/clickhouse
4. DB::HTTPServerConnection::run() @ 0xf8d35ff in /opt/InfoVista/5ViewSDM/bin/clickhouse
5. Poco::Net::TCPServerConnection::start() @ 0x11f7ccbf in /opt/InfoVista/5ViewSDM/bin/clickhouse
6. Poco::Net::TCPServerDispatcher::run() @ 0x11f7e6d1 in /opt/InfoVista/5ViewSDM/bin/clickhouse
7. Poco::PooledThread::run() @ 0x120b4df9 in /opt/InfoVista/5ViewSDM/bin/clickhouse
8. Poco::ThreadImpl::runnableEntry(void*) @ 0x120b0c5a in /opt/InfoVista/5ViewSDM/bin/clickhouse
9. start_thread @ 0x7dd5 in /usr/lib64/libpthread-2.17.so
10. __clone @ 0xfdead in /usr/lib64/libc-2.17.so
(version 21.3.2.5 (official build))
```
It does not seems to happen if I disable the client compression (but my requests are larger)
| https://github.com/ClickHouse/ClickHouse/issues/21907 | https://github.com/ClickHouse/ClickHouse/pull/22322 | c3a9cbe01c1c07d21cd1f89b31291a194fc21b25 | 3d860fc6ace8466b0159cd45af69fa0c78afe330 | "2021-03-19T10:58:55Z" | c++ | "2021-04-02T22:58:22Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,906 | ["src/Storages/Distributed/DirectoryMonitor.cpp", "src/Storages/Distributed/DistributedBlockOutputStream.cpp", "tests/queries/0_stateless/01790_dist_INSERT_block_structure_mismatch_types_and_names.reference", "tests/queries/0_stateless/01790_dist_INSERT_block_structure_mismatch_types_and_names.sql", "tests/queries/0_stateless/01791_dist_INSERT_block_structure_mismatch.reference", "tests/queries/0_stateless/01791_dist_INSERT_block_structure_mismatch.sh", "tests/queries/0_stateless/arcadia_skip_list.txt"] | DirectoryMonitor: Structure does not match | Hello,
after updating clickhouse from 21.2.3.15-2 to 21.3.2.5-2 I see those warnings :
`<Warning> default.osb4_reverse.DirectoryMonitor: Structure does not match (remote: Path LowCardinality(String) ColumnLowCardinality(size = 0, UInt8(size = 0), ColumnUnique(size = 1, String(size = 1))), Value Float64 Float64(size = 0), Time UInt32 UInt32(size = 0), Date Date UInt16(size = 0), Timestamp UInt32 UInt32(size = 0), local: Path LowCardinality(String) ColumnLowCardinality(size = 0, UInt16(size = 0), ColumnUnique(size = 1, String(size = 1))), Value Float64 Float64(size = 0), Time UInt32 UInt32(size = 0), Date Date UInt16(size = 0), Timestamp UInt32 UInt32(size = 0)), implicit conversion will be done`
I think this is related to https://github.com/ClickHouse/ClickHouse/pull/19947
The only difference between remote and local I found inside this log is :
ColumnLowCardinality(size = 0, UInt8(size = 0) to
ColumnLowCardinality(size = 0, UInt16(size = 0)
But I don't see the difference between the tables.
```
SHOW CREATE TABLE default.osb4_reverse
CREATE TABLE default.osb4_reverse
(
`Path` LowCardinality(String) CODEC(ZSTD(15)),
`Value` Float64 CODEC(Gorilla, ZSTD(22)),
`Time` UInt32 CODEC(DoubleDelta, ZSTD(15)),
`Date` Date CODEC(Delta(2), ZSTD(22)),
`Timestamp` UInt32 CODEC(ZSTD(15))
)
ENGINE = Distributed('osb4_hpc_metrics', '', 'osb4_reverse', rand())
CREATE TABLE osb4_metrics_r0.osb4_reverse
(
`Path` LowCardinality(String) CODEC(ZSTD(15)),
`Value` Float64 CODEC(Gorilla, ZSTD(22)),
`Time` UInt32 CODEC(DoubleDelta, ZSTD(15)),
`Date` Date CODEC(Delta(2), ZSTD(22)),
`Timestamp` UInt32 CODEC(ZSTD(15))
)
ENGINE = ReplicatedReplacingMergeTree('/clickhouse/clusters/osb4_hpc_metrics/tables/{table4}/data', '{host2}')
PARTITION BY toYYYYMM(Date)
ORDER BY (Path, Time)
TTL Date + toIntervalMonth(6)
SETTINGS index_granularity = 8192
```
Any hints ?
Ralph | https://github.com/ClickHouse/ClickHouse/issues/21906 | https://github.com/ClickHouse/ClickHouse/pull/22325 | 7baafcb567a18a8caa6a8a6dede2e623eba73c60 | db0550013c3158aed8ba4ded9a263312c53c0ec5 | "2021-03-19T10:48:24Z" | c++ | "2021-04-07T08:51:12Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,905 | ["CHANGELOG.md"] | Recent ClickHouse versions seem to be having problems with `remote_servers` substitution | **Describe the unexpected behaviour**
`remote_servers` substition doesn't seem to be respected.
**How to reproduce**
Problematic ClickHouse version: 21.2
The last good version: 20.x
Tested this on two docker containers: `yandex/clickhouse-server:21.2` (bad), `yandex/clickhouse-server:20.8.9.6` (good)
`/etc/clickhouse-server/config.d/config.xml`
```xml
<yandex>
<path>/var/lib/clickhouse/</path>
<tmp_path>/var/lib/clickhouse/tmp/</tmp_path>
<user_files_path>/var/lib/clickhouse/user_files/</user_files_path>
<format_schema_path>/var/lib/clickhouse/format_schemas/</format_schema_path>
<include_from>/etc/clickhouse-server/metrica.d/metrica.xml</include_from>
<users_config>users.xml</users_config>
<display_name>RELEASE-NAME-clickhouse</display_name>
<listen_host>0.0.0.0</listen_host>
<http_port>8123</http_port>
<tcp_port>9000</tcp_port>
<interserver_http_port>9009</interserver_http_port>
<max_connections>4096</max_connections>
<keep_alive_timeout>3</keep_alive_timeout>
<max_concurrent_queries>100</max_concurrent_queries>
<uncompressed_cache_size>8589934592</uncompressed_cache_size>
<mark_cache_size>5368709120</mark_cache_size>
<timezone>UTC</timezone>
<umask>022</umask>
<mlock_executable>false</mlock_executable>
<remote_servers incl="clickhouse_remote_servers" optional="true" />
<zookeeper incl="zookeeper-servers" optional="true" />
<macros incl="macros" optional="true" />
<builtin_dictionaries_reload_interval>3600</builtin_dictionaries_reload_interval>
<max_session_timeout>3600</max_session_timeout>
<default_session_timeout>60</default_session_timeout>
<disable_internal_dns_cache>1</disable_internal_dns_cache>
<query_log>
<database>system</database>
<table>query_log</table>
<partition_by>toYYYYMM(event_date)</partition_by>
<flush_interval_milliseconds>7500</flush_interval_milliseconds>
</query_log>
<query_thread_log>
<database>system</database>
<table>query_thread_log</table>
<partition_by>toYYYYMM(event_date)</partition_by>
<flush_interval_milliseconds>7500</flush_interval_milliseconds>
</query_thread_log>
<distributed_ddl>
<path>/clickhouse/task_queue/ddl</path>
</distributed_ddl>
<logger>
<level>trace</level>
<log>/var/log/clickhouse-server/clickhouse-server.log</log>
<errorlog>/var/log/clickhouse-server/clickhouse-server.err.log</errorlog>
<size>1000M</size>
<count>10</count>
</logger>
</yandex>
```
`/etc/clickhouse-server/metrica.d/metrica.xml`
```xml
<?xml version="1.0"?>
<yandex>
<clickhouse_remote_servers>
<RELEASE-NAME-clickhouse>
<shard>
<replica>
<internal_replication>true</internal_replication>
<host>RELEASE-NAME-clickhouse-0.RELEASE-NAME-clickhouse-headless.sentry.svc.cluster.local</host>
<port>9000</port>
<user>default</user>
<compression>true</compression>
</replica>
</shard>
<shard>
<replica>
<internal_replication>true</internal_replication>
<host>RELEASE-NAME-clickhouse-1.RELEASE-NAME-clickhouse-headless.sentry.svc.cluster.local</host>
<port>9000</port>
<user>default</user>
<compression>true</compression>
</replica>
</shard>
<shard>
<replica>
<internal_replication>true</internal_replication>
<host>RELEASE-NAME-clickhouse-2.RELEASE-NAME-clickhouse-headless.sentry.svc.cluster.local</host>
<port>9000</port>
<user>default</user>
<compression>true</compression>
</replica>
</shard>
</RELEASE-NAME-clickhouse>
</clickhouse_remote_servers>
</yandex>
```
I noticed that there are some changes in `/etc/clickhouse-server/config.xml` between these versions that might have something to do with this issue. Namely:
(good)
```xml
<remote_servers incl="clickhouse_remote_servers" >
```
(bad)
```xml
<remote_servers>
```
**Expected behavior**
`cluster` is created. On a good version of `Clickhouse` `RELEASE-NAME-clickhouse` cluster is available (`select * from system.clusters`) and its definition is available in the `preprocessed_configs`. On a bad version for some reason the cluster is missing.
**Error message and/or stacktrace**
None. | https://github.com/ClickHouse/ClickHouse/issues/21905 | https://github.com/ClickHouse/ClickHouse/pull/25083 | e39f25517941ffeb14ae66b543eb479eba39c0cf | c9e87ae989d6ca542a864a0aae63e8f443591b20 | "2021-03-19T10:29:19Z" | c++ | "2021-06-08T16:14:36Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,897 | ["docker/test/fasttest/run.sh", "src/Functions/FunctionsAES.h", "tests/queries/0_stateless/01776_decrypt_aead_size_check.reference", "tests/queries/0_stateless/01776_decrypt_aead_size_check.sql"] | UBSan: PODArray.h:252:25: runtime error: addition of unsigned offset overflowed | https://clickhouse-test-reports.s3.yandex.net/21846/f2ac17cfba1d3bfcc82faf0c5f9816ac04e933cd/fuzzer_tsan/report.html#fail1
```
SELECT decrypt('aes-128-gcm', 'text', 'key', 'IV')
#0 0xe95b4f2 in DB::PODArrayBase<1ul, 4096ul, Allocator<false, false>, 15ul, 16ul>::resize_assume_reserved(unsigned long) obj-x86_64-linux-gnu/../src/Common/PODArray.h:252:25
#1 0xe95b4f2 in void DB::PODArrayBase<1ul, 4096ul, Allocator<false, false>, 15ul, 16ul>::resize<>(unsigned long) obj-x86_64-linux-gnu/../src/Common/PODArray.h:240:9
#2 0x127c569c in COW<DB::IColumn>::immutable_ptr<DB::IColumn> DB::FunctionDecrypt<(anonymous namespace)::DecryptImpl>::doDecryptImpl<(OpenSSLDetails::CipherMode)2>(evp_cipher_st const*, unsigned long, COW<DB::IColumn>::immutable_ptr<DB::IColumn> const&, COW<DB::IColumn>::immutable_ptr<DB::IColumn> const&, COW<DB::IColumn>::immutable_ptr<DB::IColumn> const&, COW<DB::IColumn>::immutable_ptr<DB::IColumn> const&) (/workspace/clickhouse+0x127c569c)
#3 0x127c53f8 in DB::FunctionDecrypt<(anonymous namespace)::DecryptImpl>::doDecrypt(evp_cipher_st const*, unsigned long, COW<DB::IColumn>::immutable_ptr<DB::IColumn> const&, COW<DB::IColumn>::immutable_ptr<DB::IColumn> const&, COW<DB::IColumn>::immutable_ptr<DB::IColumn> const&, COW<DB::IColumn>::immutable_ptr<DB::IColumn> const&) (/workspace/clickhouse+0x127c53f8)
#4 0x127c4c4d in DB::FunctionDecrypt<(anonymous namespace)::DecryptImpl>::executeImpl(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long) const (/workspace/clickhouse+0x127c4c4d)
#5 0x1254b104 in DB::IFunction::executeImplDryRun(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long) const (/workspace/clickhouse+0x1254b104)
#6 0x125504e6 in DB::DefaultExecutable::executeDryRun(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long) const (/workspace/clickhouse+0x125504e6)
#7 0x12ff690a in DB::ExecutableFunctionAdaptor::executeWithoutLowCardinalityColumns(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const (/workspace/clickhouse+0x12ff690a)
#8 0x12ff5f64 in DB::ExecutableFunctionAdaptor::defaultImplementationForConstantArguments(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const (/workspace/clickhouse+0x12ff5f64)
#9 0x12ff6794 in DB::ExecutableFunctionAdaptor::executeWithoutLowCardinalityColumns(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const (/workspace/clickhouse+0x12ff6794)
#10 0x12ff790d in DB::ExecutableFunctionAdaptor::execute(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const (/workspace/clickhouse+0x12ff790d)
#11 0x1a0c87b7 in DB::ActionsDAG::addFunction(std::__1::shared_ptr<DB::IFunctionOverloadResolver> const&, std::__1::vector<DB::ActionsDAG::Node*, std::__1::allocator<DB::ActionsDAG::Node*> >, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, bool, bool) obj-x86_64-linux-gnu/../src/Interpreters/ActionsDAG.cpp:238:35
#12 0x1a0c96cd in DB::ActionsDAG::addFunction(std::__1::shared_ptr<DB::IFunctionOverloadResolver> const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, DB::Context const&, bool) obj-x86_64-linux-gnu/../src/Interpreters/ActionsDAG.cpp:192:12
#13 0x1a5f88a1 in DB::ScopeStack::addFunction(std::__1::shared_ptr<DB::IFunctionOverloadResolver> const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.cpp:501:51
#14 0x1a609e72 in DB::ActionsMatcher::Data::addFunction(std::__1::shared_ptr<DB::IFunctionOverloadResolver> const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.h:155:27
#15 0x1a600918 in DB::ActionsMatcher::visit(DB::ASTFunction const&, std::__1::shared_ptr<DB::IAST> const&, DB::ActionsMatcher::Data&) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.cpp:971:14
#16 0x1a60625f in DB::ActionsMatcher::visit(DB::ASTExpressionList&, std::__1::shared_ptr<DB::IAST> const&, DB::ActionsMatcher::Data&) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.cpp
#17 0x1a5dd541 in DB::InDepthNodeVisitor<DB::ActionsMatcher, true, std::__1::shared_ptr<DB::IAST> const>::visit(std::__1::shared_ptr<DB::IAST> const&) obj-x86_64-linux-gnu/../src/Interpreters/InDepthNodeVisitor.h:34:13
#18 0x1a5cad4f in DB::ExpressionAnalyzer::getRootActions(std::__1::shared_ptr<DB::IAST> const&, bool, std::__1::shared_ptr<DB::ActionsDAG>&, bool) obj-x86_64-linux-gnu/../src/Interpreters/ExpressionAnalyzer.cpp:410:48
#19 0x1a5d39ba in DB::SelectQueryExpressionAnalyzer::appendSelect(DB::ExpressionActionsChain&, bool) obj-x86_64-linux-gnu/../src/Interpreters/ExpressionAnalyzer.cpp:1134:5
#20 0x1a5d7d47 in DB::ExpressionAnalysisResult::ExpressionAnalysisResult(DB::SelectQueryExpressionAnalyzer&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&, bool, bool, bool, std::__1::shared_ptr<DB::FilterDAGInfo> const&, DB::Block const&) obj-x86_64-linux-gnu/../src/Interpreters/ExpressionAnalyzer.cpp:1518:24
#21 0x1a34a30d in DB::InterpreterSelectQuery::getSampleBlockImpl() obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectQuery.cpp:594:23
#22 0x1a3413cf in DB::InterpreterSelectQuery::InterpreterSelectQuery(std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, std::__1::shared_ptr<DB::IBlockInputStream> const&, std::__1::optional<DB::Pipe>, std::__1::shared_ptr<DB::IStorage> const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&)::$_2::operator()(bool) const obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectQuery.cpp:475:25
#23 0x1a33bfd8 in DB::InterpreterSelectQuery::InterpreterSelectQuery(std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, std::__1::shared_ptr<DB::IBlockInputStream> const&, std::__1::optional<DB::Pipe>, std::__1::shared_ptr<DB::IStorage> const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&) obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectQuery.cpp:478:5
#24 0x1a339b49 in DB::InterpreterSelectQuery::InterpreterSelectQuery(std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectQuery.cpp:160:7
#25 0x1a865f27 in std::__1::__unique_if<DB::InterpreterSelectQuery>::__unique_single std::__1::make_unique<DB::InterpreterSelectQuery, std::__1::shared_ptr<DB::IAST> const&, DB::Context&, DB::SelectQueryOptions&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&>(std::__1::shared_ptr<DB::IAST> const&, DB::Context&, DB::SelectQueryOptions&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) obj-x86_64-linux-gnu/../contrib/libcxx/include/memory:2068:32
#26 0x1a863913 in DB::InterpreterSelectWithUnionQuery::buildCurrentChildInterpreter(std::__1::shared_ptr<DB::IAST> const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectWithUnionQuery.cpp:210:16
#27 0x1a861e49 in DB::InterpreterSelectWithUnionQuery::InterpreterSelectWithUnionQuery(std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectWithUnionQuery.cpp:132:13
#28 0x1a2d7a75 in std::__1::__unique_if<DB::InterpreterSelectWithUnionQuery>::__unique_single std::__1::make_unique<DB::InterpreterSelectWithUnionQuery, std::__1::shared_ptr<DB::IAST>&, DB::Context&, DB::SelectQueryOptions const&>(std::__1::shared_ptr<DB::IAST>&, DB::Context&, DB::SelectQueryOptions const&) obj-x86_64-linux-gnu/../contrib/libcxx/include/memory:2068:32
#29 0x1a2d65ca in DB::InterpreterFactory::get(std::__1::shared_ptr<DB::IAST>&, DB::Context&, DB::SelectQueryOptions const&) obj-x86_64-linux-gnu/../src/Interpreters/InterpreterFactory.cpp:110:16
#30 0x1aaa6d09 in DB::executeQueryImpl(char const*, char const*, DB::Context&, bool, DB::QueryProcessingStage::Enum, bool, DB::ReadBuffer*) obj-x86_64-linux-gnu/../src/Interpreters/executeQuery.cpp:520:28
#31 0x1aaa5b54 in DB::executeQuery(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, DB::Context&, bool, DB::QueryProcessingStage::Enum, bool) obj-x86_64-linux-gnu/../src/Interpreters/executeQuery.cpp:908:30
#32 0x1b5354ca in DB::TCPHandler::runImpl() obj-x86_64-linux-gnu/../src/Server/TCPHandler.cpp:289:24
#33 0x1b54f25c in DB::TCPHandler::run() obj-x86_64-linux-gnu/../src/Server/TCPHandler.cpp:1520:9
#34 0x1c47c48b in Poco::Net::TCPServerConnection::start() obj-x86_64-linux-gnu/../contrib/poco/Net/src/TCPServerConnection.cpp:43:3
#35 0x1c47c8e2 in Poco::Net::TCPServerDispatcher::run() obj-x86_64-linux-gnu/../contrib/poco/Net/src/TCPServerDispatcher.cpp:113:19
#36 0x1c559f29 in Poco::PooledThread::run() obj-x86_64-linux-gnu/../contrib/poco/Foundation/src/ThreadPool.cpp:199:14
#37 0x1c557d2b in Poco::ThreadImpl::runnableEntry(void*) obj-x86_64-linux-gnu/../contrib/poco/Foundation/src/Thread_POSIX.cpp:345:27
#38 0x7f3f3554a608 in start_thread /build/glibc-eX1tMB/glibc-2.31/nptl/pthread_create.c:477:8
#39 0x7f3f35471292 in clone /build/glibc-eX1tMB/glibc-2.31/misc/../sysdeps/unix/sysv/linux/x86_64/clone.S:95
SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior ../src/Common/PODArray.h:252:25 in
``` | https://github.com/ClickHouse/ClickHouse/issues/21897 | https://github.com/ClickHouse/ClickHouse/pull/22064 | cb6926629e1dd0315127a460699a2c8475a6115f | 52396acba12360d093e55f1d2651e07025025463 | "2021-03-18T23:36:08Z" | c++ | "2021-03-25T13:01:44Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,876 | ["utils/CMakeLists.txt"] | Build fails on Mac OS, on assembly files from utils/memcpy-bench/memcpy_jart.S | git diff and all submodules are clean
**Operating system**
Mac OS 11.1 "Big Sur"
**Cmake version**
cmake version 3.18.4
**Ninja version**
**Compiler name and version**
llvm clang 10.0.1
```
/usr/local/opt/llvm/bin/clang++ --version
clang version 10.0.1
Target: x86_64-apple-darwin20.2.0
Thread model: posix
InstalledDir: /usr/local/opt/llvm/bin
```
**Full cmake and/or ninja output**
```
[ 88%] Building ASM object utils/memcpy-bench/CMakeFiles/memcpy-bench.dir/memcpy_jart.S.o
ClickHouse/utils/memcpy-bench/memcpy_jart.S:33:2: error: unknown directive
.type memcpy_jart,@function
^
ClickHouse/utils/memcpy-bench/memcpy_jart.S:34:2: error: unknown directive
.size memcpy_jart,.-memcpy_jart
^
ClickHouse/utils/memcpy-bench/memcpy_jart.S:115:2: error: unknown directive
.type MemCpy,@function
^
ClickHouse/utils/memcpy-bench/memcpy_jart.S:116:2: error: unknown directive
.size MemCpy,.-MemCpy
^
ClickHouse/utils/memcpy-bench/memcpy_jart.S:119:18: error: unexpected token in '.section' directive
.section .rodata
^
ClickHouse/utils/memcpy-bench/memcpy_jart.S:137:2: error: unknown directive
.type memcpytab,@object
```
| https://github.com/ClickHouse/ClickHouse/issues/21876 | https://github.com/ClickHouse/ClickHouse/pull/22056 | 4de5afed4eb15e1fc2f57721df0e464557410a43 | 2ae2539c2132cb8b00ba00809cd0686aeabbc09c | "2021-03-18T15:38:49Z" | c++ | "2021-03-24T00:43:13Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,834 | ["src/Functions/randDistribution.cpp", "tests/queries/0_stateless/02462_distributions.reference", "tests/queries/0_stateless/02462_distributions.sql"] | Generate random data with boundaries |
**Use case**
It could be useful to generate random data with boundaries.
Currently, both generateRandom functions and engine, allow to define a table like:
```sql
CREATE TABLE randomt
(
`value` Decimal(5,2),
`date` Date,
`zone_id` UInt64,
`type` Enum8('blue' = 0, 'green' = 1, 'red' = 2),
`interests` Array(String)
)
ENGINE = GenerateRandom(123, 5, 3)
```
```sql
SELECT *
FROM randomt
LIMIT 5
```
```shell
βββββββββvalueββ¬βββββββdateββ¬ββββββββββββββzone_idββ¬βtypeβββ¬βinterestsβββββββ
β 17418655.70 β 2018-08-16 β 9921422126199728620 β green β ['(nX'] β
β -2712197.83 β 1992-12-19 β 1576572515264284063 β blue β ['','8NM','I'] β
β 15070040.36 β 2102-11-15 β 688226268395004343 β blue β ['b7<ZU','m*'] β
β -16219929.50 β 2033-01-18 β 12076865034075318107 β red β ['3'] β
β 2771016.64 β 2051-03-21 β 8931155881545802352 β blue β ['oU',';!>V'] β
ββββββββββββββββ΄βββββββββββββ΄βββββββββββββββββββββββ΄ββββββββ΄βββββββββββββββββ
```
It works great for fuzzing test and some other things, but I'm thinking in the use case of generated 'mock' data with limits for each column.
For some fields (date and enum), the behaviour is correct (in the sense of mock data).
```sql
SELECT *
FROM randomt
WHERE (date = toDate('2020-10-20')) AND (type = 'blue')
LIMIT 5
```
```shell
ββββββββvalueββ¬βββββββdateββ¬ββββββββββββββzone_idββ¬βtypeββ¬βinterestsββ
β -459221.48 β 2020-10-20 β 16696499279086187682 β blue β ['R'] β
β -5533672.64 β 2020-10-20 β 5903887098779430673 β blue β [] β
βββββββββββββββ΄βββββββββββββ΄βββββββββββββββββββββββ΄βββββββ΄ββββββββββββ
ββββββββvalueββ¬βββββββdateββ¬ββββββββββββββzone_idββ¬βtypeββ¬βinterestsββββββββββββββ
β 7419336.56 β 2020-10-20 β 4113108383613272096 β blue β ['A','~5^H+','"X@'] β
β -2742208.19 β 2020-10-20 β 17036311104628448725 β blue β [' 4 5:','Nd?0','f9'] β
βββββββββββββββ΄βββββββββββββ΄βββββββββββββββββββββββ΄βββββββ΄ββββββββββββββββββββββββ
βββββββvalueββ¬βββββββdateββ¬ββββββββββββββzone_idββ¬βtypeββ¬βinterestsββ
β 3702796.40 β 2020-10-20 β 18297471488954938545 β blue β [] β
ββββββββββββββ΄βββββββββββββ΄βββββββββββββββββββββββ΄βββββββ΄ββββββββββββ
```
But when selecting others like:
```sql
select * from randomt where date=toDate('2020-10-20') and type='blue' and zone_id in (array(1,2,3)) limit 5
```
The query hangs out.
**Describe the solution you'd like**
What if is possible something like:
```sql
CREATE TABLE randomt
(
`value` Decimal(5,2) [min=0, max=100]
`date` Date, [min=toDate('2020-10-01', max=toDate('2021,03-03')
`zone_id` UInt64, [min=0, max=2000]
`type` Enum8('blue' = 0, 'green' = 1, 'red' = 2),
`interests` Array(String) (select interest in another_table)
)
ENGINE = GenerateRandom(123, 5, 3)
```
The syntax could be other, of course, it just as an example to illustrate.
For strings, min and max probably hasn't make sense, so something like a list of values could be useful.
**Describe alternatives you've considered**
clickhouse-obfuscated, but it would take too much disk space for the use case.
**Additional context**
If it doesn't make sense, or there are currently better alternatives, just say it :)
| https://github.com/ClickHouse/ClickHouse/issues/21834 | https://github.com/ClickHouse/ClickHouse/pull/42411 | 0d8a814d80f715f9eeb9efad18337fb4836593cd | 9a73eb2fbbcdc199458f09dcc3e7c52e6b4f8071 | "2021-03-17T13:25:16Z" | c++ | "2022-10-20T15:25:28Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,773 | ["src/Interpreters/ActionsDAG.cpp", "src/Interpreters/ActionsDAG.h", "src/Processors/QueryPlan/Optimizations/filterPushDown.cpp", "tests/queries/0_stateless/01763_filter_push_down_bugs.reference", "tests/queries/0_stateless/01763_filter_push_down_bugs.sql"] | Would use 1.00 EiB ... while executing ConvertingAggregatedToChunksTransform | Abnormal memory requirements for a query with string filter
Appeared fresh after upgrade to 21.3.2.5
The table is not big - 480 mb compressed
Getting an error
```
SQL Error [241]: ClickHouse exception, code: 241, host: localhost, port: 8123; Code: 241, e.displayText() = DB::Exception: Memory limit (for query) exceeded: would use 1.00 EiB (attempt to allocate chunk of 1152921504606554384 bytes), maximum: 101.47 GiB: While executing ConvertingAggregatedToChunksTransform (version 21.3.2.5 (official build))
The query is quite plain
SELECT
FirstScreen,
"SessionResult" AS "SessionResult",
count(*) AS count
FROM
(SELECT FirstScreen,
SessionResult,
LastResponse,
toDate(LastResponseDateTime),
WasEligible,
WasSessionSuccessfull,
COUNT (*)
FROM MPTUSSDSESSIONS
GROUP by FirstScreen,
SessionResult,
LastResponse,
toDate(LastResponseDateTime),
WasEligible,
WasSessionSuccessfull) AS expr_qry
WHERE "SessionResult" NOT IN ('unknown result')
AND "WasSessionSuccessfull" ='Y'
GROUP BY FirstScreen, "SessionResult"
ORDER BY count DESC
LIMIT 10000;
```
Most interesting - when line `AND "WasSessionSuccessfull" ='Y' ` is removed from the query it completes ok. | https://github.com/ClickHouse/ClickHouse/issues/21773 | https://github.com/ClickHouse/ClickHouse/pull/21841 | b8a437c35adc40cf91dc6961d76c655790ec4b6e | 03cb0299a94cf72519784e22aa8ee6b3564858b1 | "2021-03-16T09:37:29Z" | c++ | "2021-03-18T10:30:22Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,755 | ["src/Storages/MergeTree/MergeTreeData.cpp"] | Multidisk setup & reused zookeeper path | When i reuse the same zookeeper path I get the following misleading exception:
```
Received exception from server (version 21.1.6):
Code: 1000. DB::Exception: Received from clickhouse101.demo.trial.altinity.cloud:9440. DB::Exception: File not found: /var/lib/clickhouse3/store/f18/f183d094-a0e5-429a-ac96-5f8b663fcfe7/format_version.txt. Stack trace:
0. Poco::FileImpl::handleLastErrorImpl(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&) @ 0x11e8b81f in /usr/bin/clickhouse
1. Poco::FileImpl::removeImpl() @ 0x11e8ca7e in /usr/bin/clickhouse
2. Poco::File::remove(bool) @ 0x11e8ede1 in /usr/bin/clickhouse
3. DB::DiskLocal::remove(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&) @ 0xea6a702 in /usr/bin/clickhouse
4. DB::MergeTreeData::dropIfEmpty() @ 0xf5c3694 in /usr/bin/clickhouse
5. DB::StorageReplicatedMergeTree::StorageReplicatedMergeTree(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, bool, DB::StorageID const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, DB::StorageInMemoryMetadata const&, DB::Context&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, DB::MergeTreeData::MergingParams const&, std::__1::unique_ptr<DB::MergeTreeSettings, std::__1::default_delete<DB::MergeTreeSettings> >, bool, bool) @ 0xf3cce72 in /usr/bin/clickhouse
6. std::__1::shared_ptr<DB::StorageReplicatedMergeTree> ext::shared_ptr_helper<DB::StorageReplicatedMergeTree>::create<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >&, bool const&, DB::StorageID const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, DB::StorageInMemoryMetadata&, DB::Context&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >&, DB::MergeTreeData::MergingParams&, std::__1::unique_ptr<DB::MergeTreeSettings, std::__1::default_delete<DB::MergeTreeSettings> >, bool const&, bool&>(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >&, bool const&, DB::StorageID const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, DB::StorageInMemoryMetadata&, DB::Context&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >&, DB::MergeTreeData::MergingParams&, std::__1::unique_ptr<DB::MergeTreeSettings, std::__1::default_delete<DB::MergeTreeSettings> >&&, bool const&, bool&) @ 0xf7abd23 in /usr/bin/clickhouse
7. ? @ 0xf7a4fd8 in /usr/bin/clickhouse
8. std::__1::__function::__func<std::__1::shared_ptr<DB::IStorage> (*)(DB::StorageFactory::Arguments const&), std::__1::allocator<std::__1::shared_ptr<DB::IStorage> (*)(DB::StorageFactory::Arguments const&)>, std::__1::shared_ptr<DB::IStorage> (DB::StorageFactory::Arguments const&)>::operator()(DB::StorageFactory::Arguments const&) @ 0xf5445cd in /usr/bin/clickhouse
9. DB::StorageFactory::get(DB::ASTCreateQuery const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, DB::Context&, DB::Context&, DB::ColumnsDescription const&, DB::ConstraintsDescription const&, bool) const @ 0xf30e60a in /usr/bin/clickhouse
10. DB::InterpreterCreateQuery::doCreateTable(DB::ASTCreateQuery&, DB::InterpreterCreateQuery::TableProperties const&) @ 0xec4113e in /usr/bin/clickhouse
11. DB::InterpreterCreateQuery::createTable(DB::ASTCreateQuery&) @ 0xec3e9cd in /usr/bin/clickhouse
12. DB::InterpreterCreateQuery::execute() @ 0xec43677 in /usr/bin/clickhouse
13. ? @ 0xf163e79 in /usr/bin/clickhouse
14. DB::executeQuery(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, DB::Context&, bool, DB::QueryProcessingStage::Enum, bool) @ 0xf1627ed in /usr/bin/clickhouse
15. DB::TCPHandler::runImpl() @ 0xf86cdc6 in /usr/bin/clickhouse
16. DB::TCPHandler::run() @ 0xf87bbd7 in /usr/bin/clickhouse
17. Poco::Net::TCPServerConnection::start() @ 0x11dbfbcf in /usr/bin/clickhouse
18. Poco::Net::TCPServerDispatcher::run() @ 0x11dc15e1 in /usr/bin/clickhouse
19. Poco::PooledThread::run() @ 0x11eecf69 in /usr/bin/clickhouse
20. Poco::ThreadImpl::runnableEntry(void*) @ 0x11ee8efa in /usr/bin/clickhouse
21. start_thread @ 0x9609 in /usr/lib/x86_64-linux-gnu/libpthread-2.31.so
22. clone @ 0x122293 in /usr/lib/x86_64-linux-gnu/libc-2.31.so
``` | https://github.com/ClickHouse/ClickHouse/issues/21755 | https://github.com/ClickHouse/ClickHouse/pull/23433 | 41ed8aab59b41904cce159b71a1b7ef49aa8a435 | c66e715f49b6d6a423921a6c342875e12d46e982 | "2021-03-15T16:46:44Z" | c++ | "2021-04-24T00:34:06Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,721 | ["docs/en/sql-reference/statements/create/view.md", "src/Core/Settings.h", "src/Interpreters/SystemLog.cpp", "src/Processors/Transforms/buildPushingToViewsChain.cpp", "tests/queries/0_stateless/02572_materialized_views_ignore_errors.reference", "tests/queries/0_stateless/02572_materialized_views_ignore_errors.sql", "tests/queries/0_stateless/02572_system_logs_materialized_views_ignore_errors.reference", "tests/queries/0_stateless/02572_system_logs_materialized_views_ignore_errors.sql"] | A new setting to allow (suppress) errors during an insert into Materialized Views. | A new setting for Materialized Views (e.g. suppress_insert_exceptions=1) to silently skip (suppress) errors.
For example we have a materialized view which logs inserts into table Engine=Remote and we want to skip insertion errors into this MV. | https://github.com/ClickHouse/ClickHouse/issues/21721 | https://github.com/ClickHouse/ClickHouse/pull/46658 | 65d671b7c72c7b1da23f831faa877565cf34f92c | 575ffbc4653b117e918356c8e60f7748df956643 | "2021-03-15T00:16:29Z" | c++ | "2023-03-09T11:19:48Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,698 | ["debian/clickhouse-common-static.install", "debian/clickhouse-server.config", "debian/clickhouse-server.postinst", "debian/clickhouse-server.preinst", "debian/clickhouse-server.prerm", "debian/clickhouse-server.templates", "debian/clickhouse.limits", "debian/rules", "debian/watch", "programs/install/Install.cpp"] | Setting password during installation | I installed a CH from debian repos (just copied from docs) and installation process asking me for a password, I typed my testing password ended by "();" witouth quotes.
After install I can access without any password.
users.xml show like "<password></password>" for default user.
Β―\\\_(γ)\_/Β―
| https://github.com/ClickHouse/ClickHouse/issues/21698 | https://github.com/ClickHouse/ClickHouse/pull/22976 | 7614a18ff27703f0055300c29e9e962521a43a38 | ca03670e60cfec19c84e1dfb683e74a0eb3ae65c | "2021-03-13T10:42:43Z" | c++ | "2021-04-14T21:17:05Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,632 | ["src/Functions/FunctionsExternalDictionaries.h", "src/Interpreters/ExternalDictionariesLoader.h", "src/Interpreters/ExternalLoader.cpp", "src/Interpreters/ExternalLoader.h", "tests/queries/0_stateless/01760_ddl_dictionary_use_current_database_name.reference", "tests/queries/0_stateless/01760_ddl_dictionary_use_current_database_name.sql"] | dictGet without database for SQL dictionaries. | dictGet('name', ...) should check for XML dictionary 'name' if XML dict=name does not exists then use SQL dictionary from the currectDatabase()
| https://github.com/ClickHouse/ClickHouse/issues/21632 | https://github.com/ClickHouse/ClickHouse/pull/21859 | b5e344bf49155402f9de14f1eec9eb6e919a09da | f340e71913758a54038b26e53189e59234aa885a | "2021-03-11T16:56:05Z" | c++ | "2021-03-19T08:39:51Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,620 | ["src/Dictionaries/PolygonDictionary.cpp", "src/Dictionaries/PolygonDictionary.h", "src/Dictionaries/PolygonDictionaryImplementations.cpp", "src/Dictionaries/PolygonDictionaryImplementations.h", "src/Dictionaries/PolygonDictionaryUtils.cpp", "src/Dictionaries/PolygonDictionaryUtils.h", "tests/queries/0_stateless/01760_polygon_dictionaries.reference", "tests/queries/0_stateless/01760_polygon_dictionaries.sql", "tests/queries/skip_list.json"] | bytes_allocated for polygon dictionaries is 0, even when loaded | ```
SELECT *
FROM system.dictionaries
WHERE name LIKE 'XXXX%'
Row 1:
ββββββ
database: default
name: XXXX_dict
uuid: 00000000-0000-0000-0000-000000000000
status: LOADED
origin: default.XXXX_dict
type: Polygon
key: (Array(Array(Array(Array(Float64)))))
attribute.names: ['name','id']
attribute.types: ['String','String']
bytes_allocated: 0
query_count: 0
hit_rate: 1
element_count: 433731
load_factor: 1
source: ClickHouse: default.XXXX
lifetime_min: 60
lifetime_max: 1800
loading_start_time: 2021-03-11 00:07:52
last_successful_update_time: 2021-03-11 00:08:24
loading_duration: 31.595
last_exception:
``` | https://github.com/ClickHouse/ClickHouse/issues/21620 | https://github.com/ClickHouse/ClickHouse/pull/21890 | af25805a7017223c9f2b4c3f289ee95484ef92fb | 330e74b665a6a33799b4516940d41e0ac8b472e4 | "2021-03-11T09:33:17Z" | c++ | "2021-03-22T11:49:28Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,613 | ["src/Functions/array/arrayAggregation.cpp", "tests/queries/0_stateless/01768_array_product.reference", "tests/queries/0_stateless/01768_array_product.sql"] | arrayProduct | for the last year I replied 3 times with a silly snippet:
```
SELECT
[2, 3, 4] AS x,
pow(2, arraySum(i -> log2(i), x)) AS arrayProduct
ββxββββββββ¬βarrayProductββ
β [2,3,4] β 24 β
βββββββββββ΄βββββββββββββββ
```
I think we need a function to multiply elements of an array. | https://github.com/ClickHouse/ClickHouse/issues/21613 | https://github.com/ClickHouse/ClickHouse/pull/23782 | 9f633205893ded3cdf6a8a74aeeb9c803042a773 | fa1e9de7f7325f5d90aea083fd8c1cc2925a6790 | "2021-03-11T01:05:47Z" | c++ | "2021-04-30T21:53:57Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,592 | ["tests/queries/0_stateless/01911_logical_error_minus.reference", "tests/queries/0_stateless/01911_logical_error_minus.sql"] | Arguments of 'minus' have incorrect data types: '' of type 'UInt64', '' of type 'Nullable(Nothing)'' | https://clickhouse-test-reports.s3.yandex.net/0/f4db00bdb28617f621ce87ba5ddeab7f2fc720d6/fuzzer_debug/report.html#fail1
**Describe the bug**
```
Logical error: 'Arguments of 'minus' have incorrect data types: '' of type 'UInt64', '' of type 'Nullable(Nothing)''. Logical error: 'Arguments of 'minus' have incorrect data types: '' of type 'UInt64', '' of type 'Nullable(Nothing)''. Logical error: 'Arguments of 'minus' have incorrect data types: '' of type 'UInt64', '' of type 'Nullable(Nothing)''. Logical error: 'Arguments of 'minus' have incorrect data types: '' of type 'UInt64', '' of type 'Nullable(Nothing)''. Received signal 6 Received signal 6 Received signal 6 Received signal Aborted (6) Received signal 6 Received signal Aborted (6) Received signal Aborted (6) Received signal Aborted (6)
```
```
2021.03.10 11:11:47.023948 [ 190 ] {} <Fatal> BaseDaemon: ########################################
2021.03.10 11:11:47.024210 [ 190 ] {} <Fatal> BaseDaemon: (version 21.4.1.6205 (official build), build id: BEA3104DD62E8813C613FB195D11284AE38DC15B) (from thread 186) (query_id: 5285987f-0870-427f-b147-f597e18db11d) Received signal Aborted (6)
2021.03.10 11:11:47.024544 [ 190 ] {} <Fatal> BaseDaemon:
2021.03.10 11:11:47.024920 [ 190 ] {} <Fatal> BaseDaemon: Stack trace: 0x7fa6255df18b 0x7fa6255be859 0x10e77d96 0x10e77e53 0x13f5af71 0x1442941c 0x1454b8a9 0x14428cc9 0x132a24fb 0x13337e88 0x1aa54d4b 0x1aa435f4 0x1aa44602 0x1aa48b34 0x1aa42f88 0x1aa42b9f 0x1aa44f20 0x1ab56d69 0x1ab447ef 0x1ab50d5d 0x1ab5990d 0x1ab5985d 0x1ab5982d 0x1ab59805 0x1ab597e0 0x10ebec09 0x10ebdf25 0x10ee301e 0x10eeca34 0x10eec9fd 0x10eec9b1 0x10eec8f2 0x10eec7e7 0x10eec71d 0x10eec6ed 0x10eec6c5 0x10eec6a0 0x10ebec09 0x10ebdf25 0x10ee149e 0x10ee8804 0x10ee878d 0x10ee86e5 0x10ee80b2 0x7fa625794609 0x7fa6256bb293
2021.03.10 11:11:47.025404 [ 190 ] {} <Fatal> BaseDaemon: 4. raise @ 0x4618b in /usr/lib/x86_64-linux-gnu/libc-2.31.so
2021.03.10 11:11:47.025565 [ 190 ] {} <Fatal> BaseDaemon: 5. abort @ 0x25859 in /usr/lib/x86_64-linux-gnu/libc-2.31.so
2021.03.10 11:11:47.145114 [ 190 ] {} <Fatal> BaseDaemon: 6. ./obj-x86_64-linux-gnu/../src/Common/Exception.cpp:50: DB::handle_error_code(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, int) @ 0x10e77d96 in /workspace/clickhouse
2021.03.10 11:11:47.251608 [ 190 ] {} <Fatal> BaseDaemon: 7. ./obj-x86_64-linux-gnu/../src/Common/Exception.cpp:57: DB::Exception::Exception(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, int, bool) @ 0x10e77e53 in /workspace/clickhouse
2021.03.10 11:11:47.643561 [ 190 ] {} <Fatal> BaseDaemon: 8. ./obj-x86_64-linux-gnu/../src/Common/Exception.h:38: DB::Exception::Exception<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >(int, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >&&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >&&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >&&) @ 0x13f5af71 in /workspace/clickhouse
2021.03.10 11:11:48.184743 [ 190 ] {} <Fatal> BaseDaemon: 9. ./obj-x86_64-linux-gnu/../src/Functions/FunctionBinaryArithmetic.h:1295: DB::FunctionBinaryArithmetic<DB::MinusImpl, DB::NameMinus, true, true>::executeImpl(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long) const @ 0x1442941c in /workspace/clickhouse
2021.03.10 11:11:48.919344 [ 190 ] {} <Fatal> BaseDaemon: 10. ./obj-x86_64-linux-gnu/../src/Functions/FunctionBinaryArithmetic.h:1471: DB::FunctionBinaryArithmeticWithConstants<DB::MinusImpl, DB::NameMinus, true, true>::getMonotonicityForRange(DB::IDataType const&, DB::Field const&, DB::Field const&) const::'lambda0'(DB::Field const&)::operator()(DB::Field const&) const @ 0x1454b8a9 in /workspace/clickhouse
2021.03.10 11:11:49.428371 [ 190 ] {} <Fatal> BaseDaemon: 11. ./obj-x86_64-linux-gnu/../src/Functions/FunctionBinaryArithmetic.h:1479: DB::FunctionBinaryArithmeticWithConstants<DB::MinusImpl, DB::NameMinus, true, true>::getMonotonicityForRange(DB::IDataType const&, DB::Field const&, DB::Field const&) const @ 0x14428cc9 in /workspace/clickhouse
2021.03.10 11:11:49.655194 [ 190 ] {} <Fatal> BaseDaemon: 12. ./obj-x86_64-linux-gnu/../src/Functions/IFunctionAdaptors.h:213: DB::DefaultFunction::getMonotonicityForRange(DB::IDataType const&, DB::Field const&, DB::Field const&) const @ 0x132a24fb in /workspace/clickhouse
2021.03.10 11:11:50.008386 [ 190 ] {} <Fatal> BaseDaemon: 13. ./obj-x86_64-linux-gnu/../src/Functions/IFunctionAdaptors.h:78: DB::FunctionBaseAdaptor::getMonotonicityForRange(DB::IDataType const&, DB::Field const&, DB::Field const&) const @ 0x13337e88 in /workspace/clickhouse
2021.03.10 11:11:51.160016 [ 190 ] {} <Fatal> BaseDaemon: 14. ./obj-x86_64-linux-gnu/../src/Storages/MergeTree/KeyCondition.cpp:935: DB::FunctionWithOptionalConstArg::getMonotonicityForRange(DB::IDataType const&, DB::Field const&, DB::Field const&) const @ 0x1aa54d4b in /workspace/clickhouse
2021.03.10 11:11:52.199020 [ 190 ] {} <Fatal> BaseDaemon: 15. ./obj-x86_64-linux-gnu/../src/Storages/MergeTree/KeyCondition.cpp:1487: DB::KeyCondition::applyMonotonicFunctionsChainToRange(DB::Range, std::__1::vector<std::__1::shared_ptr<DB::IFunctionBase>, std::__1::allocator<std::__1::shared_ptr<DB::IFunctionBase> > > const&, std::__1::shared_ptr<DB::IDataType const>, bool) @ 0x1aa435f4 in /workspace/clickhouse
2021.03.10 11:11:53.239246 [ 190 ] {} <Fatal> BaseDaemon: 16. ./obj-x86_64-linux-gnu/../src/Storages/MergeTree/KeyCondition.cpp:1614: DB::KeyCondition::checkInHyperrectangle(std::__1::vector<DB::Range, std::__1::allocator<DB::Range> > const&, std::__1::vector<std::__1::shared_ptr<DB::IDataType const>, std::__1::allocator<std::__1::shared_ptr<DB::IDataType const> > > const&) const @ 0x1aa44602 in /workspace/clickhouse
2021.03.10 11:11:54.747832 [ 190 ] {} <Fatal> BaseDaemon: 17. ./obj-x86_64-linux-gnu/../src/Storages/MergeTree/KeyCondition.cpp:1464: DB::KeyCondition::checkInRange(unsigned long, DB::FieldRef const*, DB::FieldRef const*, std::__1::vector<std::__1::shared_ptr<DB::IDataType const>, std::__1::allocator<std::__1::shared_ptr<DB::IDataType const> > > const&, bool, BoolMask) const::$_17::operator()(std::__1::vector<DB::Range, std::__1::allocator<DB::Range> > const&) const @ 0x1aa48b34 in /workspace/clickhouse
2021.03.10 11:11:56.236982 [ 190 ] {} <Fatal> BaseDaemon: 18. ./obj-x86_64-linux-gnu/../src/Storages/MergeTree/KeyCondition.cpp:1387: BoolMask DB::forAnyHyperrectangle<DB::KeyCondition::checkInRange(unsigned long, DB::FieldRef const*, DB::FieldRef const*, std::__1::vector<std::__1::shared_ptr<DB::IDataType const>, std::__1::allocator<std::__1::shared_ptr<DB::IDataType const> > > const&, bool, BoolMask) const::$_17>(unsigned long, DB::FieldRef const*, DB::FieldRef const*, bool, bool, std::__1::vector<DB::Range, std::__1::allocator<DB::Range> >&, unsigned long, BoolMask, DB::KeyCondition::checkInRange(unsigned long, DB::FieldRef const*, DB::FieldRef const*, std::__1::vector<std::__1::shared_ptr<DB::IDataType const>, std::__1::allocator<std::__1::shared_ptr<DB::IDataType const> > > const&, bool, BoolMask) const::$_17&&) @ 0x1aa42f88 in /workspace/clickhouse
2021.03.10 11:11:57.297102 [ 190 ] {} <Fatal> BaseDaemon: 19. ./obj-x86_64-linux-gnu/../src/Storages/MergeTree/KeyCondition.cpp:1461: DB::KeyCondition::checkInRange(unsigned long, DB::FieldRef const*, DB::FieldRef const*, std::__1::vector<std::__1::shared_ptr<DB::IDataType const>, std::__1::allocator<std::__1::shared_ptr<DB::IDataType const> > > const&, bool, BoolMask) const @ 0x1aa42b9f in /workspace/clickhouse
2021.03.10 11:11:58.343695 [ 190 ] {} <Fatal> BaseDaemon: 20. ./obj-x86_64-linux-gnu/../src/Storages/MergeTree/KeyCondition.cpp:1708: DB::KeyCondition::mayBeTrueInRange(unsigned long, DB::FieldRef const*, DB::FieldRef const*, std::__1::vector<std::__1::shared_ptr<DB::IDataType const>, std::__1::allocator<std::__1::shared_ptr<DB::IDataType const> > > const&) const @ 0x1aa44f20 in /workspace/clickhouse
2021.03.10 11:11:59.111110 [ 190 ] {} <Fatal> BaseDaemon: 21. ./obj-x86_64-linux-gnu/../src/Storages/MergeTree/MergeTreeDataSelectExecutor.cpp:1702: DB::MergeTreeDataSelectExecutor::markRangesFromPKRange(std::__1::shared_ptr<DB::IMergeTreeDataPart const> const&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&, DB::KeyCondition const&, DB::Settings const&, Poco::Logger*)::$_6::operator()(DB::MarkRange&) const @ 0x1ab56d69 in /workspace/clickhouse
2021.03.10 11:11:59.839367 [ 190 ] {} <Fatal> BaseDaemon: 22. ./obj-x86_64-linux-gnu/../src/Storages/MergeTree/MergeTreeDataSelectExecutor.cpp:1732: DB::MergeTreeDataSelectExecutor::markRangesFromPKRange(std::__1::shared_ptr<DB::IMergeTreeDataPart const> const&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&, DB::KeyCondition const&, DB::Settings const&, Poco::Logger*) @ 0x1ab447ef in /workspace/clickhouse
2021.03.10 11:12:00.608938 [ 190 ] {} <Fatal> BaseDaemon: 23. ./obj-x86_64-linux-gnu/../src/Storages/MergeTree/MergeTreeDataSelectExecutor.cpp:643: DB::MergeTreeDataSelectExecutor::readFromParts(std::__1::vector<std::__1::shared_ptr<DB::IMergeTreeDataPart const>, std::__1::allocator<std::__1::shared_ptr<DB::IMergeTreeDataPart const> > >, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&, DB::SelectQueryInfo const&, DB::Context const&, unsigned long, unsigned int, std::__1::unordered_map<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, long, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::allocator<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, long> > > const*) const::$_2::operator()(unsigned long) const @ 0x1ab50d5d in /workspace/clickhouse
2021.03.10 11:12:01.449050 [ 190 ] {} <Fatal> BaseDaemon: 24. ./obj-x86_64-linux-gnu/../src/Storages/MergeTree/MergeTreeDataSelectExecutor.cpp:709: DB::MergeTreeDataSelectExecutor::readFromParts(std::__1::vector<std::__1::shared_ptr<DB::IMergeTreeDataPart const>, std::__1::allocator<std::__1::shared_ptr<DB::IMergeTreeDataPart const> > >, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&, DB::SelectQueryInfo const&, DB::Context const&, unsigned long, unsigned int, std::__1::unordered_map<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, long, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::allocator<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, long> > > const*) const::$_3::operator()() const @ 0x1ab5990d in /workspace/clickhouse
2021.03.10 11:12:02.291655 [ 190 ] {} <Fatal> BaseDaemon: 25. ./obj-x86_64-linux-gnu/../contrib/libcxx/include/type_traits:3676: decltype(std::__1::forward<DB::MergeTreeDataSelectExecutor::readFromParts(std::__1::vector<std::__1::shared_ptr<DB::IMergeTreeDataPart const>, std::__1::allocator<std::__1::shared_ptr<DB::IMergeTreeDataPart const> > >, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&, DB::SelectQueryInfo const&, DB::Context const&, unsigned long, unsigned int, std::__1::unordered_map<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, long, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::allocator<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, long> > > const*) const::$_3&>(fp)()) std::__1::__invoke<DB::MergeTreeDataSelectExecutor::readFromParts(std::__1::vector<std::__1::shared_ptr<DB::IMergeTreeDataPart const>, std::__1::allocator<std::__1::shared_ptr<DB::IMergeTreeDataPart const> > >, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&, DB::SelectQueryInfo const&, DB::Context const&, unsigned long, unsigned int, std::__1::unordered_map<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, long, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::allocator<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, long> > > const*) const::$_3&>(DB::MergeTreeDataSelectExecutor::readFromParts(std::__1::vector<std::__1::shared_ptr<DB::IMergeTreeDataPart const>, std::__1::allocator<std::__1::shared_ptr<DB::IMergeTreeDataPart const> > >, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&, DB::SelectQueryInfo const&, DB::Context const&, unsigned long, unsigned int, std::__1::unordered_map<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, long, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::allocator<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, long> > > const*) const::$_3&) @ 0x1ab5985d in /workspace/clickhouse
2021.03.10 11:12:03.101084 [ 190 ] {} <Fatal> BaseDaemon: 26. ./obj-x86_64-linux-gnu/../contrib/libcxx/include/__functional_base:349: void std::__1::__invoke_void_return_wrapper<void>::__call<DB::MergeTreeDataSelectExecutor::readFromParts(std::__1::vector<std::__1::shared_ptr<DB::IMergeTreeDataPart const>, std::__1::allocator<std::__1::shared_ptr<DB::IMergeTreeDataPart const> > >, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&, DB::SelectQueryInfo const&, DB::Context const&, unsigned long, unsigned int, std::__1::unordered_map<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, long, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::allocator<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, long> > > const*) const::$_3&>(DB::MergeTreeDataSelectExecutor::readFromParts(std::__1::vector<std::__1::shared_ptr<DB::IMergeTreeDataPart const>, std::__1::allocator<std::__1::shared_ptr<DB::IMergeTreeDataPart const> > >, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&, DB::SelectQueryInfo const&, DB::Context const&, unsigned long, unsigned int, std::__1::unordered_map<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, long, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::allocator<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, long> > > const*) const::$_3&) @ 0x1ab5982d in /workspace/clickhouse
2021.03.10 11:12:03.915199 [ 190 ] {} <Fatal> BaseDaemon: 27. ./obj-x86_64-linux-gnu/../contrib/libcxx/include/functional:1608: std::__1::__function::__default_alloc_func<DB::MergeTreeDataSelectExecutor::readFromParts(std::__1::vector<std::__1::shared_ptr<DB::IMergeTreeDataPart const>, std::__1::allocator<std::__1::shared_ptr<DB::IMergeTreeDataPart const> > >, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&, DB::SelectQueryInfo const&, DB::Context const&, unsigned long, unsigned int, std::__1::unordered_map<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, long, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::allocator<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, long> > > const*) const::$_3, void ()>::operator()() @ 0x1ab59805 in /workspace/clickhouse
2021.03.10 11:12:04.731472 [ 190 ] {} <Fatal> BaseDaemon: 28. ./obj-x86_64-linux-gnu/../contrib/libcxx/include/functional:2089: void std::__1::__function::__policy_invoker<void ()>::__call_impl<std::__1::__function::__default_alloc_func<DB::MergeTreeDataSelectExecutor::readFromParts(std::__1::vector<std::__1::shared_ptr<DB::IMergeTreeDataPart const>, std::__1::allocator<std::__1::shared_ptr<DB::IMergeTreeDataPart const> > >, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&, DB::SelectQueryInfo const&, DB::Context const&, unsigned long, unsigned int, std::__1::unordered_map<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, long, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::allocator<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, long> > > const*) const::$_3, void ()> >(std::__1::__function::__policy_storage const*) @ 0x1ab597e0 in /workspace/clickhouse
2021.03.10 11:12:04.948429 [ 190 ] {} <Fatal> BaseDaemon: 29. ./obj-x86_64-linux-gnu/../contrib/libcxx/include/functional:2221: std::__1::__function::__policy_func<void ()>::operator()() const @ 0x10ebec09 in /workspace/clickhouse
2021.03.10 11:12:05.163788 [ 190 ] {} <Fatal> BaseDaemon: 30. ./obj-x86_64-linux-gnu/../contrib/libcxx/include/functional:2560: std::__1::function<void ()>::operator()() const @ 0x10ebdf25 in /workspace/clickhouse
2021.03.10 11:12:05.240894 [ 190 ] {} <Fatal> BaseDaemon: 31. ./obj-x86_64-linux-gnu/../src/Common/ThreadPool.cpp:247: ThreadPoolImpl<ThreadFromGlobalPool>::worker(std::__1::__list_iterator<ThreadFromGlobalPool, void*>) @ 0x10ee301e in /workspace/clickhouse
2021.03.10 11:12:05.327800 [ 190 ] {} <Fatal> BaseDaemon: 32. ./obj-x86_64-linux-gnu/../src/Common/ThreadPool.cpp:124: void ThreadPoolImpl<ThreadFromGlobalPool>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()::operator()() const @ 0x10eeca34 in /workspace/clickhouse
2021.03.10 11:12:05.411046 [ 190 ] {} <Fatal> BaseDaemon: 33. ./obj-x86_64-linux-gnu/../contrib/libcxx/include/type_traits:3682: decltype(std::__1::forward<void>(fp)(std::__1::forward<void ThreadPoolImpl<ThreadFromGlobalPool>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()&>(fp0)...)) std::__1::__invoke_constexpr<void ThreadPoolImpl<ThreadFromGlobalPool>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()&>(void&&, void ThreadPoolImpl<ThreadFromGlobalPool>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()&...) @ 0x10eec9fd in /workspace/clickhouse
2021.03.10 11:12:05.493996 [ 190 ] {} <Fatal> BaseDaemon: 34. ./obj-x86_64-linux-gnu/../contrib/libcxx/include/tuple:1415: decltype(auto) std::__1::__apply_tuple_impl<void ThreadPoolImpl<ThreadFromGlobalPool>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()&, std::__1::tuple<>&>(void&&, void ThreadPoolImpl<ThreadFromGlobalPool>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()&, std::__1::__tuple_indices<std::__1::tuple<>&...>) @ 0x10eec9b1 in /workspace/clickhouse
2021.03.10 11:12:05.576544 [ 190 ] {} <Fatal> BaseDaemon: 35. ./obj-x86_64-linux-gnu/../contrib/libcxx/include/tuple:1424: decltype(auto) std::__1::apply<void ThreadPoolImpl<ThreadFromGlobalPool>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()&, std::__1::tuple<>&>(void&&, void ThreadPoolImpl<ThreadFromGlobalPool>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()&) @ 0x10eec8f2 in /workspace/clickhouse
2021.03.10 11:12:05.663372 [ 190 ] {} <Fatal> BaseDaemon: 36. ./obj-x86_64-linux-gnu/../src/Common/ThreadPool.h:178: ThreadFromGlobalPool::ThreadFromGlobalPool<void ThreadPoolImpl<ThreadFromGlobalPool>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()>(void&&, void ThreadPoolImpl<ThreadFromGlobalPool>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()&&...)::'lambda'()::operator()() @ 0x10eec7e7 in /workspace/clickhouse
2021.03.10 11:12:05.745885 [ 190 ] {} <Fatal> BaseDaemon: 37. ./obj-x86_64-linux-gnu/../contrib/libcxx/include/type_traits:3676: decltype(std::__1::forward<void>(fp)(std::__1::forward<void ThreadPoolImpl<ThreadFromGlobalPool>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()>(fp0)...)) std::__1::__invoke<ThreadFromGlobalPool::ThreadFromGlobalPool<void ThreadPoolImpl<ThreadFromGlobalPool>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()>(void&&, void ThreadPoolImpl<ThreadFromGlobalPool>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()&&...)::'lambda'()&>(void&&, void ThreadPoolImpl<ThreadFromGlobalPool>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()&&...) @ 0x10eec71d in /workspace/clickhouse
2021.03.10 11:12:05.833287 [ 190 ] {} <Fatal> BaseDaemon: 38. ./obj-x86_64-linux-gnu/../contrib/libcxx/include/__functional_base:349: void std::__1::__invoke_void_return_wrapper<void>::__call<ThreadFromGlobalPool::ThreadFromGlobalPool<void ThreadPoolImpl<ThreadFromGlobalPool>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()>(void&&, void ThreadPoolImpl<ThreadFromGlobalPool>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()&&...)::'lambda'()&>(void&&...) @ 0x10eec6ed in /workspace/clickhouse
2021.03.10 11:12:05.920438 [ 190 ] {} <Fatal> BaseDaemon: 39. ./obj-x86_64-linux-gnu/../contrib/libcxx/include/functional:1608: std::__1::__function::__default_alloc_func<ThreadFromGlobalPool::ThreadFromGlobalPool<void ThreadPoolImpl<ThreadFromGlobalPool>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()>(void&&, void ThreadPoolImpl<ThreadFromGlobalPool>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()&&...)::'lambda'(), void ()>::operator()() @ 0x10eec6c5 in /workspace/clickhouse
2021.03.10 11:12:06.008463 [ 190 ] {} <Fatal> BaseDaemon: 40. ./obj-x86_64-linux-gnu/../contrib/libcxx/include/functional:2089: void std::__1::__function::__policy_invoker<void ()>::__call_impl<std::__1::__function::__default_alloc_func<ThreadFromGlobalPool::ThreadFromGlobalPool<void ThreadPoolImpl<ThreadFromGlobalPool>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()>(void&&, void ThreadPoolImpl<ThreadFromGlobalPool>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()&&...)::'lambda'(), void ()> >(std::__1::__function::__policy_storage const*) @ 0x10eec6a0 in /workspace/clickhouse
2021.03.10 11:12:06.236240 [ 190 ] {} <Fatal> BaseDaemon: 41. ./obj-x86_64-linux-gnu/../contrib/libcxx/include/functional:2221: std::__1::__function::__policy_func<void ()>::operator()() const @ 0x10ebec09 in /workspace/clickhouse
2021.03.10 11:12:06.462941 [ 190 ] {} <Fatal> BaseDaemon: 42. ./obj-x86_64-linux-gnu/../contrib/libcxx/include/functional:2560: std::__1::function<void ()>::operator()() const @ 0x10ebdf25 in /workspace/clickhouse
2021.03.10 11:12:06.541120 [ 190 ] {} <Fatal> BaseDaemon: 43. ./obj-x86_64-linux-gnu/../src/Common/ThreadPool.cpp:247: ThreadPoolImpl<std::__1::thread>::worker(std::__1::__list_iterator<std::__1::thread, void*>) @ 0x10ee149e in /workspace/clickhouse
2021.03.10 11:12:06.629102 [ 190 ] {} <Fatal> BaseDaemon: 44. ./obj-x86_64-linux-gnu/../src/Common/ThreadPool.cpp:124: void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()::operator()() const @ 0x10ee8804 in /workspace/clickhouse
2021.03.10 11:12:06.713450 [ 190 ] {} <Fatal> BaseDaemon: 45. ./obj-x86_64-linux-gnu/../contrib/libcxx/include/type_traits:3676: decltype(std::__1::forward<void>(fp)(std::__1::forward<void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()>(fp0)...)) std::__1::__invoke<void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()>(void&&, void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()&&...) @ 0x10ee878d in /workspace/clickhouse
2021.03.10 11:12:06.794735 [ 190 ] {} <Fatal> BaseDaemon: 46. ./obj-x86_64-linux-gnu/../contrib/libcxx/include/thread:281: void std::__1::__thread_execute<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()>(std::__1::tuple<void, void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()>&, std::__1::__tuple_indices<>) @ 0x10ee86e5 in /workspace/clickhouse
2021.03.10 11:12:06.876754 [ 190 ] {} <Fatal> BaseDaemon: 47. ./obj-x86_64-linux-gnu/../contrib/libcxx/include/thread:291: void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()> >(void*) @ 0x10ee80b2 in /workspace/clickhouse
2021.03.10 11:12:06.877131 [ 190 ] {} <Fatal> BaseDaemon: 48. start_thread @ 0x9609 in /usr/lib/x86_64-linux-gnu/libpthread-2.31.so
2021.03.10 11:12:06.877529 [ 190 ] {} <Fatal> BaseDaemon: 49. clone @ 0x122293 in /usr/lib/x86_64-linux-gnu/libc-2.31.so
```
**How to reproduce**
```
SELECT IF(-2, NULL, 0.00009999999747378752), IF(1048577, 1048576, NULL), c1.key, IF(1, NULL, NULL), c2.key FROM codecTest AS c1 , codecTest AS c2 WHERE ignore(IF(257, -2, NULL), arrayJoin([65537]), IF(3, 1024, 9223372036854775807)) AND IF(NULL, 256, NULL) AND (IF(NULL, '1048576', NULL) = (c1.key - NULL)) LIMIT 65535
``` | https://github.com/ClickHouse/ClickHouse/issues/21592 | https://github.com/ClickHouse/ClickHouse/pull/25262 | 35ef7266dbec1f04758a5e756af0d4b5e7001ec4 | d822ba1f3b89b62da981823e035c8ff9ca10c4ca | "2021-03-10T13:32:56Z" | c++ | "2021-10-03T09:09:28Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,588 | ["src/DataStreams/RemoteQueryExecutorReadContext.cpp", "src/DataStreams/RemoteQueryExecutorReadContext.h"] | Unknown packet XX from server | Some queries to distributed table fail with this error
`
2021.03.10 09:55:07.000828 [ 8466 ] {88a44f07-ba05-443a-88cc-14fd260b8297} <Error> executeQuery: Code: 100, e.displayText() = DB::Exception: Unknown packet 97 from server node2-dal13-sl.systems:9000 (version 21.2.5.5 (official build)) (from 54.208.201.221:35979) (in query: SELECT domain AS domain, url AS url, uri AS uri, ip AS ip, method AS method, status_code AS status_code, conviction__rule_name AS rule_name, country AS country, computed_action AS action, conviction__rule_id AS rule_id, id AS id, ua AS ua, ua_parsed__client AS ua_parsed_client, organization AS organization, toInt64(timestamp) AS timestamp, conviction__reference_id AS reference_id, result AS result, traffic_type AS traffic_type FROM default.logs WHERE (((bitTest(traffic_type_query, 1) = 1)) AND domain='82deae48a65148a881b4bdfbd4c5deec.stackpathdns.com' AND timestamp>=1615283645000 AND timestamp<1615370045000) ORDER BY timestamp DESC LIMIT 100 FORMAT JSONCompact ), Stack trace (when copying this message, always include the lines below):
0. DB::Connection::receivePacket(std::__1::function<void (Poco::Net::Socket&)>) @ 0xf517cc5 in /usr/bin/clickhouse
1. DB::MultiplexedConnections::receivePacketUnlocked(std::__1::function<void (Poco::Net::Socket&)>) @ 0xf525b75 in /usr/bin/clickhouse
2. DB::MultiplexedConnections::drain() @ 0xf5262b0 in /usr/bin/clickhouse
3. DB::RemoteQueryExecutor::finish(std::__1::unique_ptr<DB::RemoteQueryExecutorReadContext, std::__1::default_delete<DB::RemoteQueryExecutorReadContext> >*) @ 0xe6ad867 in /usr/bin/clickhouse
4. DB::PipelineExecutor::tryAddProcessorToStackIfUpdated(DB::ExecutingGraph::Edge&, std::__1::queue<DB::ExecutingGraph::Node*, std::__1::deque<DB::ExecutingGraph::Node*, std::__1::allocator<DB::ExecutingGraph::Node*> > >&, std::__1::queue<DB::ExecutingGraph::Node*, std::__1::deque<DB::ExecutingGraph::Node*, std::__1::allocator<DB::ExecutingGraph::Node*> > >&, unsigned long) @ 0xf63ad1c in /usr/bin/clickhouse
5. DB::PipelineExecutor::prepareProcessor(unsigned long, unsigned long, std::__1::queue<DB::ExecutingGraph::Node*, std::__1::deque<DB::ExecutingGraph::Node*, std::__1::allocator<DB::ExecutingGraph::Node
*> > >&, std::__1::queue<DB::ExecutingGraph::Node*, std::__1::deque<DB::ExecutingGraph::Node*, std::__1::allocator<DB::ExecutingGraph::Node*> > >&, std::__1::unique_lock<std::__1::mutex>) @ 0xf63b4e9 in
/usr/bin/clickhouse
6. DB::PipelineExecutor::executeStepImpl(unsigned long, unsigned long, std::__1::atomic<bool>*) @ 0xf63e9f0 in /usr/bin/clickhouse
7. ? @ 0xf642f26 in /usr/bin/clickhouse
8. ThreadPoolImpl<std::__1::thread>::worker(std::__1::__list_iterator<std::__1::thread, void*>) @ 0x84f700f in /usr/bin/clickhouse
9. ? @ 0x84faaa3 in /usr/bin/clickhouse
10. start_thread @ 0x7ea5 in /usr/lib64/libpthread-2.17.so
11. clone @ 0xfe96d in /usr/lib64/libc-2.17.so
`
you can see query example in the error message
default.logs is a distributed table. We have 3 nodes cluster running clickhouse-server version 21.2.5.5
| https://github.com/ClickHouse/ClickHouse/issues/21588 | https://github.com/ClickHouse/ClickHouse/pull/21643 | f9bead5f33350b61fbb64d551f41e4e5520161e2 | 0ffea300acb5d7e7e82e28b8dc20e18046eec3b0 | "2021-03-10T10:42:49Z" | c++ | "2021-03-16T12:51:49Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,556 | ["src/Storages/MergeTree/MergeTreeWhereOptimizer.cpp", "tests/queries/0_stateless/01824_move_to_prewhere_many_columns.reference", "tests/queries/0_stateless/01824_move_to_prewhere_many_columns.sql"] | Performance degradation when migrating to 21.1 | After we migrate to new the newest releases of ClickHouse, we started to notice a considerable performance degradation in almost all of our queries.
Specifically, we migrated from 20.12 to 21.1.
### Query
Here is one of our simplest queries that got affected:
```sql
SELECT
ProjectId,
UserId,
SessionId,
Url,
EntryUrl,
ExitUrl,
Browser,
BrowserVersion,
Device,
OS,
OSVersion,
Country
FROM clarity.page_data_all
WHERE (ProjectId = <id>) AND ((SessionStart >= '2021/03/03 00:00:00') AND (SessionStart <= '2021/03/08 00:00:00')) AND (Playback = 1)
ORDER BY SessionStart DESC
LIMIT 100
```
In `clickhouse-server` version `20.12`:
```
100 rows in set. Elapsed: 0.074 sec. Processed 10.88 million rows, 304.95 MB (147.38 million rows/s., 4.13 GB/s.)
```
In `clickhouse-server` version `21.1`:
```
100 rows in set. Elapsed: 0.181 sec. Processed 10.88 million rows, 3.16 GB (59.98 million rows/s., 17.39 GB/s.)
```
There is a 100 ms increase in latency in the newest version, and this increase is consistent when running the query several times.
**Note:** both versions were running on the exact same data.
### Table Schema
This is a simplified version of our table schema:
```sql
CREATE TABLE IF NOT EXISTS clarity.page_data_local
(
Timestamp DateTime,
ProjectId UInt64,
UserId UInt32,
SessionId UInt32,
PageNum UInt8,
Device UInt8,
OS UInt8,
OSVersion Nullable(String),
Browser UInt8,
BrowserVersion Nullable(String),
Country UInt8,
Url Nullable(String),
EntryUrl Nullable(String),
ExitUrl Nullable(String),
SessionStart DateTime,
Playback UInt8,
)
ENGINE = ReplicatedMergeTree('/clickhouse/tables/clarity/page_data_local/{shard}', '{replica}')
PARTITION BY toYYYYMM(Timestamp)
ORDER BY (ProjectId, Date, intHash32(UserId), SessionId, PageNum)
SAMPLE BY intHash32(UserId)
```
### Profile Events
And here are the profile events of the two versions:
| Event | Old (v20.12) | New (v21.21) | Diff |
| ------|-----|-----|------|
| Query | 1.00 | 1.00 | 0.00 |
| SelectQuery | 1.00 | 1.00 | 0.00 |
| FileOpen | 741.00 | 703.00 | 38.00 |
| Seek | 166.00 | 417.00 | -251.00 |
| ReadBufferFromFileDescriptorRead | 212.00 | 790.00 | -578.00 |
| ReadBufferFromFileDescriptorReadBytes | 56633195.00 | 225970859.00 | -169337664.00 |
| ReadCompressedBytes | 40778823.00 | 173846053.00 | -133067230.00 |
| CompressedReadBufferBlocks | 956.00 | 6810.00 | -5854.00 |
| CompressedReadBufferBytes | 151034072.00 | 1499238564.00 | -1348204492.00 |
| IOBufferAllocs | 942.00 | 1410.00 | -468.00 |
| IOBufferAllocBytes | 171385503.00 | 218698263.00 | -47312760.00 |
| FunctionExecute | 5173.00 | 7155.00 | -1982.00 |
| MarkCacheHits | 741.00 | 703.00 | 38.00 |
| CreatedReadBufferOrdinary | 741.00 | 703.00 | 38.00 |
| DiskReadElapsedMicroseconds | 24000.00 | 88000.00 | -64000.00 |
| NetworkReceiveElapsedMicroseconds | 56534.00 | 150364.00 | -93830.00 |
| NetworkSendElapsedMicroseconds | 266.00 | 407.00 | -141.00 |
| SelectedParts | 29.00 | 29.00 | 0.00 |
| SelectedRanges | 29.00 | 29.00 | 0.00 |
| SelectedMarks | 1155.00 | 1155.00 | 0.00 |
| SelectedRows | 10881313.00 | 10881313.00 | 0.00 |
| SelectedBytes | 305029428.00 | 3155152423.00 | -2850122995.00 |
| ContextLock | 159.00 | 161.00 | -2.00 |
| RWLockAcquiredReadLocks | 3.00 | 3.00 | 0.00 |
| RealTimeMicroseconds | 658422.00 | 1856185.00 | -1197763.00 |
| UserTimeMicroseconds | 163011.00 | 1213301.00 | -1050290.00 |
| SystemTimeMicroseconds | 65631.00 | 169707.00 | -104076.00 |
| SoftPageFaults | 18305.00 | 8868.00 | 9437.00 |
| OSCPUWaitMicroseconds | 37.00 | 193.00 | -156.00 |
| OSCPUVirtualTimeMicroseconds | 228617.00 | 99.00 | 228518.00 |
| OSWriteBytes | 24576.00 | 1382946.00 | -1358370.00 |
| OSReadChars | 56662016.00 | 24576.00 | 56637440.00 |
| OSWriteChars | 76800.00 | 225998848.00 | -225922048.00 | | https://github.com/ClickHouse/ClickHouse/issues/21556 | https://github.com/ClickHouse/ClickHouse/pull/23397 | 877d245d8f10a14ad3c4fdfed4120acb1f3d3bce | 2cfc2c8825008767e1479c8d1e9e7ea8a2c132fc | "2021-03-09T13:06:25Z" | c++ | "2021-04-24T01:39:33Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,539 | ["src/Storages/MergeTree/KeyCondition.cpp", "tests/queries/0_stateless/01540_verbatim_partition_pruning.reference", "tests/queries/0_stateless/01540_verbatim_partition_pruning.sql"] | Equals Comparison betwenn Date and String fails with special Partition Key | **Describe the bug**
Under certain conditions the equals comparison between String and Date yields the wrong result. Range Comparisons with greather-than-equals returns the correct result set.
**How to reproduce**
* Which ClickHouse server version to use: 21.2.5.5 (latest at the time of this issue)
* Which interface to use, if matters: HTTP (but should not matter)
```sql
CREATE TABLE default.myTable (
myDay Date,
myOrder Int32,
someData String
)
ENGINE = ReplacingMergeTree
PARTITION BY floor(toYYYYMMDD(myDay), -1)
ORDER BY (myOrder)
;
INSERT INTO default.myTable (myDay, myOrder) VALUES ('2021-01-01', 1);
INSERT INTO default.myTable (myDay, myOrder) VALUES ('2021-01-02', 2); // This row should be returned
INSERT INTO default.myTable (myDay, myOrder) VALUES ('2021-01-03', 3);
SELECT * FROM default.myTable mt
WHERE myDay = '2021-01-02';
```
**Expected behavior**
The last query in the example should yield the marked row. Instead it returns a empty result set.
There must be a connection to the used `PARTITION KEY`. The issue fails to reproduce as soon as I do any changes to the `PARTITION KEY` setting.
| https://github.com/ClickHouse/ClickHouse/issues/21539 | https://github.com/ClickHouse/ClickHouse/pull/23310 | 013555907cb17a7a13f4184c2e0224fb8b4f09cc | 186b1128d013de950a6a98a68f840ef39d11b4ef | "2021-03-09T06:17:12Z" | c++ | "2021-04-27T04:13:18Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,536 | ["docs/en/engines/database-engines/materialized-mysql.md", "src/Common/mysqlxx/mysqlxx/Types.h", "src/Core/MySQL/MySQLReplication.cpp", "src/DataTypes/DataTypeString.cpp", "src/DataTypes/DataTypesNumber.cpp", "src/Databases/MySQL/MaterializedMySQLSyncThread.cpp", "src/Interpreters/MySQL/InterpretersMySQLDDLQuery.cpp", "src/Interpreters/MySQL/tests/gtest_create_rewritten.cpp", "src/Processors/Sources/MySQLSource.cpp", "tests/integration/test_materialized_mysql_database/materialize_with_ddl.py"] | MaterializeMySQL not support data type 'time' | when I create table in MySQL like below:
create table test1(a time PRIMARY key);
Code: 50. DB::Exception: Received from 172.17.6.55:9100. DB::Exception: Unknown data type family: time: While executing MYSQL_QUERY_EVENT. The query: create table test1(a time PRIMARY key).
We need to synchronize data from Mysql to Clickhouse in real timeοΌmany field types are involved in the source DB, including data type 'time', so I wonder if this type will be supported in the futureοΌ
@zhang2014
MySQL VersionοΌ5.7.25
Clickhouse VersionοΌ21.2.5.5 | https://github.com/ClickHouse/ClickHouse/issues/21536 | https://github.com/ClickHouse/ClickHouse/pull/33429 | 677a7f1133c7e176dc38b291d54f63f0207e8799 | 9e91a9dfd1dae8072d9d2132a4b3e4bbb70e1c1d | "2021-03-09T01:00:26Z" | c++ | "2022-01-26T08:29:46Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,481 | ["src/Interpreters/Cluster.cpp", "src/Interpreters/MutationsInterpreter.cpp", "src/Interpreters/MutationsInterpreter.h", "tests/config/config.d/clusters.xml", "tests/queries/0_stateless/01753_mutate_table_predicated_with_table.reference", "tests/queries/0_stateless/01753_mutate_table_predicated_with_table.sql", "tests/queries/0_stateless/01754_cluster_all_replicas_shard_num.reference", "tests/queries/0_stateless/01754_cluster_all_replicas_shard_num.sql", "tests/server-test.xml"] | _shard_num and clusterAllReplicas() |
**Bug description**
Unlike `cluster()`, `clusterAllReplicas()` does not implement `_shard_num`.
I would expect
```
SELECT _shard_num
FROM clusterAllReplicas(prod, system.one)
ORDER BY _shard_num ASC
FORMAT PrettyCompactMonoBlock
ββ_shard_numββ
β 0 β
β 0 β
β 0 β
β 0 β
β 0 β
β 0 β
β 0 β
β 0 β
β 0 β
β 0 β
β 0 β
β 0 β
β 0 β
β 0 β
β 0 β
β 0 β
β 0 β
β 0 β
β 0 β
β 0 β
β 0 β
β 0 β
β 0 β
β 0 β
β 0 β
β 0 β
β 0 β
β 0 β
β 0 β
β 0 β
ββββββββββββββ
```
to have an output more useful like
```
SELECT _shard_num
FROM cluster(prod, system.one)
ORDER BY _shard_num ASC
FORMAT PrettyCompactMonoBlock
ββ_shard_numββ
β 1 β
β 2 β
β 3 β
β 4 β
β 5 β
β 6 β
β 7 β
β 8 β
β 9 β
β 10 β
β 11 β
β 12 β
β 13 β
β 14 β
β 15 β
ββββββββββββββ
```
**Releases where this has been tested**
* v20.3.12.112-stable
**References**
[cluster, clusterAllReplicas documentation](https://clickhouse.tech/docs/en/sql-reference/table-functions/cluster/)
[_shard_num documentation](https://clickhouse.tech/docs/en/engines/table-engines/special/distributed/#virtual-columns)
| https://github.com/ClickHouse/ClickHouse/issues/21481 | https://github.com/ClickHouse/ClickHouse/pull/21498 | 88113ccb990637b1726b54509efdb33e1dda3bdb | 858d1fe5939c3911dca2d6975e102219509d1569 | "2021-03-06T00:21:32Z" | c++ | "2021-03-29T20:21:08Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,469 | ["tests/queries/0_stateless/02690_subquery_identifiers.reference", "tests/queries/0_stateless/02690_subquery_identifiers.sql"] | Query fails when it is wrapped with `select * from (...)` | **Describe the bug**
**How to reproduce**
* Which ClickHouse server version to use
Latest version in Arcadia.
* `CREATE TABLE` statements for all tables involved
```sql
di.man.yp-c.yandex.net :) create table t_str (creation_time String) engine = MergeTree() partition by creation_time order by creation_time
CREATE TABLE t_str
(
`creation_time` String
)
ENGINE = MergeTree
PARTITION BY creation_time
ORDER BY creation_time
```
* Sample data for all these tables
```sql
insert into t_str values ('2020-02-02')
```
* Queries to run that lead to unexpected result
This query works well:
```sql
di.man.yp-c.yandex.net :) select 1 as x from t_str where cast('1970-01-01' as date) <= cast((select max('1970-01-01') from numbers(1)) as date)
SELECT 1 AS x
FROM t_str
WHERE CAST('1970-01-01', 'date') <= CAST(
(
SELECT max('1970-01-01')
FROM numbers(1)
), 'date')
Query id: 6ff4732e-88e3-4c95-856d-03f7a0ba494b
ββxββ
β 1 β
βββββ
1 rows in set. Elapsed: 0.012 sec.
```
But when it is wrapped with `select * from (...)` it throws an error:
```sql
di.man.yp-c.yandex.net :) select * from ( select 1 as x from t_str where cast('1970-01-01' as date) <= cast((select max('1970-01-01') from numbers(1)) as date) )
SELECT *
FROM
(
SELECT 1 AS x
FROM t_str
WHERE CAST('1970-01-01', 'date') <= CAST(
(
SELECT max('1970-01-01')
FROM numbers(1)
), 'date')
)
Query id: c9c2e5b1-5bc5-4068-a653-a46f9c568cf0
0 rows in set. Elapsed: 0.007 sec.
Received exception from server (version 21.3.1):
Code: 38. DB::Exception: Received from localhost:9000. DB::Exception: Cannot parse date: value is too short: Cannot parse Date from String: while executing 'FUNCTION CAST(_subquery2 : 7, 'date' : 2) -> CAST(_subquery2, 'date') Date : 8'.
```
**Expected behavior**
The second query should return the same value as the first one.
**Error message and/or stacktrace**
Received exception from server (version 21.3.1):
Code: 38. DB::Exception: Received from localhost:9000. DB::Exception: Cannot parse date: value is too short: Cannot parse Date from String: while executing 'FUNCTION CAST(_subquery2 : 7, 'date' : 2) -> CAST(_subquery2, 'date') Date : 8'.
| https://github.com/ClickHouse/ClickHouse/issues/21469 | https://github.com/ClickHouse/ClickHouse/pull/47736 | 329a762dedb1d6961fde199675e5ef2f565ff016 | f78e9dec492352dc083405828791b82ce558f1a7 | "2021-03-05T07:26:46Z" | c++ | "2023-03-20T12:05:39Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,437 | ["src/Processors/Formats/Impl/AvroRowInputFormat.cpp", "src/Processors/Formats/Impl/AvroRowInputFormat.h", "tests/integration/test_storage_kafka/test.py"] | loading more than one Avro formatted message from kafka does not work | In recent ClickHouse versions (21.3) Avro format for kafka does not work at all.
In ClickHouse 20.3 one Avro formatted kafka message can read, than stall forever.
Reportedly in ClickHouse prior 20.3 Avro formatted kafka messages work Ok while contain only single record | https://github.com/ClickHouse/ClickHouse/issues/21437 | https://github.com/ClickHouse/ClickHouse/pull/21438 | 61dee8c05660531dfc16fed3d2dff63f354852df | c8b5be636f443031e1ef392717218906119a9e17 | "2021-03-04T08:19:04Z" | c++ | "2021-03-19T14:06:55Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,435 | ["PreLoad.cmake", "cmake/add_warning.cmake", "cmake/linux/default_libs.cmake", "contrib/krb5-cmake/CMakeLists.txt", "contrib/protobuf-cmake/CMakeLists.txt", "contrib/sysroot", "docker/test/fasttest/run.sh", "docker/test/pvs/Dockerfile", "src/Common/renameat2.cpp"] | Unable to run integration tests if Ubuntu 20.10 host | Ubuntu 20.10 has glibc 2.32 and ClickHouse built in a plain way has two symbols marked GLIBC_2.32,
namely
```
ilejn@ilejn-Latitude-5400:~/projects/ClickHouse/build$ objdump -T ./programs/clickhouse | grep GLIBC_2.32
0000000000000000 DF *UND* 0000000000000000 GLIBC_2.32 pthread_sigmask
0000000000000000 DF *UND* 0000000000000000 GLIBC_2.32 pthread_getattr_np
``` | https://github.com/ClickHouse/ClickHouse/issues/21435 | https://github.com/ClickHouse/ClickHouse/pull/30011 | 4082c6c4e569249b209cc5f7b035b318bd3e0118 | e1c2e629d8c077193f951cdb02fac9c0b1631c65 | "2021-03-03T22:32:24Z" | c++ | "2021-11-25T02:27:25Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,419 | ["src/Storages/StorageReplicatedMergeTree.cpp", "src/Storages/StorageReplicatedMergeTree.h", "tests/queries/0_stateless/01305_replica_create_drop_zookeeper.sh"] | 01305_replica_create_drop_zookeeper flap | https://clickhouse-test-reports.s3.yandex.net/0/bd7b540b8255475ad584e814a8eeeb1386645fda/functional_stateless_tests_(release).html#fail1
server logs
```
2021.03.03 07:12:43.919384 [ 34343 ] {9e90754b-c3a1-4c51-a7a1-697104df992d} <Error> TCPHandler: Code: 999, e.displayText() = DB::Exception: Can't get data for node /clickhouse/tables/test_01305/alter_table/metadata: node doesn't exist (No
node), Stack trace:
0. Coordination::Exception::Exception(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, Coordination::Error, int) @ 0xfbcd5c3 in /usr/lib/debug/.build-id/1c/f54413784e79ae4a9d0206c5db6611836f80c4
.debug
1. Coordination::Exception::Exception(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, Coordination::Error) @ 0xfbcd842 in /usr/lib/debug/.build-id/1c/f54413784e79ae4a9d0206c5db6611836f80c4.debu
g
2. zkutil::ZooKeeper::get(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, Coordination::Stat*, std::__1::shared_ptr<Poco::Event> const&) @ 0xfbd4ad2 in /usr/lib/debug/.build-id/1c/f54413784e79a
e4a9d0206c5db6611836f80c4.debug
3. DB::StorageReplicatedMergeTree::checkTableStructure(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&) @ 0xf3b8f13 in /usr/lib/de
bug/.build-id/1c/f54413784e79ae4a9d0206c5db6611836f80c4.debug
4. DB::StorageReplicatedMergeTree::StorageReplicatedMergeTree(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>
> const&, bool, DB::StorageID const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, DB::StorageInMemoryMetadata const&, DB::Context&, std::__1::basic_string<char, std::__1::char_traits<char>
, std::__1::allocator<char> > const&, DB::MergeTreeData::MergingParams const&, std::__1::unique_ptr<DB::MergeTreeSettings, std::__1::default_delete<DB::MergeTreeSettings> >, bool, bool) @ 0xf3b2965 in /usr/lib/debug/.build-id/1c/f54413784e
79ae4a9d0206c5db6611836f80c4.debug
5. DB::create(DB::StorageFactory::Arguments const&) @ 0xf7acdbf in /usr/lib/debug/.build-id/1c/f54413784e79ae4a9d0206c5db6611836f80c4.debug
6. DB::StorageFactory::get(DB::ASTCreateQuery const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, DB::Context&, DB::Context&, DB::ColumnsDescription const&, DB::ConstraintsDescription const
&, bool) const @ 0xf2fcf59 in /usr/lib/debug/.build-id/1c/f54413784e79ae4a9d0206c5db6611836f80c4.debug
7. DB::InterpreterCreateQuery::doCreateTable(DB::ASTCreateQuery&, DB::InterpreterCreateQuery::TableProperties const&) @ 0xebcc0b4 in /usr/lib/debug/.build-id/1c/f54413784e79ae4a9d0206c5db6611836f80c4.debug
8. DB::InterpreterCreateQuery::createTable(DB::ASTCreateQuery&) @ 0xebc8f52 in /usr/lib/debug/.build-id/1c/f54413784e79ae4a9d0206c5db6611836f80c4.debug
9. DB::InterpreterCreateQuery::execute() @ 0xebce4d0 in /usr/lib/debug/.build-id/1c/f54413784e79ae4a9d0206c5db6611836f80c4.debug
10. DB::executeQueryImpl(char const*, char const*, DB::Context&, bool, DB::QueryProcessingStage::Enum, bool, DB::ReadBuffer*) @ 0xf11d9f2 in /usr/lib/debug/.build-id/1c/f54413784e79ae4a9d0206c5db6611836f80c4.debug
11. DB::executeQuery(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, DB::Context&, bool, DB::QueryProcessingStage::Enum, bool) @ 0xf11c333 in /usr/lib/debug/.build-id/1c/f54413784e79ae4a9d0206c
5db6611836f80c4.debug
12. DB::TCPHandler::runImpl() @ 0xf8927ad in /usr/lib/debug/.build-id/1c/f54413784e79ae4a9d0206c5db6611836f80c4.debug
13. DB::TCPHandler::run() @ 0xf8a4b39 in /usr/lib/debug/.build-id/1c/f54413784e79ae4a9d0206c5db6611836f80c4.debug
14. Poco::Net::TCPServerConnection::start() @ 0x11f5642f in /usr/lib/debug/.build-id/1c/f54413784e79ae4a9d0206c5db6611836f80c4.debug
15. Poco::Net::TCPServerDispatcher::run() @ 0x11f57e41 in /usr/lib/debug/.build-id/1c/f54413784e79ae4a9d0206c5db6611836f80c4.debug
16. Poco::PooledThread::run() @ 0x1208e569 in /usr/lib/debug/.build-id/1c/f54413784e79ae4a9d0206c5db6611836f80c4.debug
17. Poco::ThreadImpl::runnableEntry(void*) @ 0x1208a3ca in /usr/lib/debug/.build-id/1c/f54413784e79ae4a9d0206c5db6611836f80c4.debug
18. start_thread @ 0x9609 in /usr/lib/x86_64-linux-gnu/libpthread-2.31.so
19. __clone @ 0x122293 in /usr/lib/x86_64-linux-gnu/libc-2.31.so
``` | https://github.com/ClickHouse/ClickHouse/issues/21419 | https://github.com/ClickHouse/ClickHouse/pull/23294 | 20a5fed53e8d1ad572d865ce1f322149f5a13c11 | 6c5ff3db7d195fc76952e9671766d78ede6aa6d2 | "2021-03-03T15:27:51Z" | c++ | "2021-04-21T13:06:15Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,388 | ["src/Interpreters/InterpreterCreateQuery.cpp", "src/Storages/StorageFactory.cpp", "src/Storages/StorageURL.cpp", "src/Storages/StorageURL.h", "src/TableFunctions/ITableFunction.cpp", "src/TableFunctions/ITableFunctionXDBC.cpp", "src/TableFunctions/ITableFunctionXDBC.h", "tests/integration/test_odbc_interaction/test.py"] | 21.2.3: range_hashed dictionary with ClickHouse source over a VIEW with odbc/jdbc function - possible dangling reference to Context | This issue happens on production of one user that enabled Sentry:

Build id: 49938CCB63EE2A4E16CF0528307EE15F08469219. | https://github.com/ClickHouse/ClickHouse/issues/21388 | https://github.com/ClickHouse/ClickHouse/pull/21913 | 40a99b7431e49aba57a30c1b73a200776fba3cc0 | ae62bee939b536ccfd04700486ee68dd21444726 | "2021-03-02T21:23:04Z" | c++ | "2021-03-26T07:39:13Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,383 | ["src/Functions/visitParamExtractBool.cpp", "src/Functions/visitParamExtractFloat.cpp", "src/Functions/visitParamExtractInt.cpp", "src/Functions/visitParamExtractRaw.cpp", "src/Functions/visitParamExtractString.cpp", "src/Functions/visitParamExtractUInt.cpp", "src/Functions/visitParamHas.cpp", "tests/queries/0_stateless/00539_functions_for_working_with_json.reference", "tests/queries/0_stateless/00539_functions_for_working_with_json.sql"] | Add aliases to visitParam (e.g. JSONS (Simplified)) | visitParamHas -> JSONSHas
visitParamExtractUInt -> JSONSExtractUInt
| https://github.com/ClickHouse/ClickHouse/issues/21383 | https://github.com/ClickHouse/ClickHouse/pull/21519 | f380d641fac3220d38368791e62af739e6d2c926 | b80951b06a948dca6c6719c8edf3e9e081d4d7bf | "2021-03-02T19:07:30Z" | c++ | "2021-04-02T07:31:32Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,197 | ["src/Core/Settings.h", "tests/queries/0_stateless/01753_max_uri_size.sh"] | Make maximum URL size configurable and raise it to 1 MiB by default | Use case:
See #21187 | https://github.com/ClickHouse/ClickHouse/issues/21197 | https://github.com/ClickHouse/ClickHouse/pull/22997 | e731dfe650e4c77aafbd608ab379e4372ebbcd6c | e687fc320fa76537ca04b5502bd38949c78e8458 | "2021-02-25T16:27:04Z" | c++ | "2021-04-13T08:26:23Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,191 | ["contrib/mariadb-connector-c-cmake/CMakeLists.txt"] | Enable MySQL in MacOS builds | null | https://github.com/ClickHouse/ClickHouse/issues/21191 | https://github.com/ClickHouse/ClickHouse/pull/46316 | 1564b94761950fd942bc2ffab429fe91ee5d6190 | ec15e68348b28ad2cf3da0fcd3551a348d4f5428 | "2021-02-25T13:37:04Z" | c++ | "2024-01-01T19:36:47Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,170 | ["src/Interpreters/InterpreterSelectWithUnionQuery.cpp", "src/Interpreters/NormalizeSelectWithUnionQueryVisitor.cpp", "src/Interpreters/NormalizeSelectWithUnionQueryVisitor.h", "src/Interpreters/executeQuery.cpp", "src/Interpreters/ya.make", "tests/queries/0_stateless/01732_explain_syntax_union_query.reference", "tests/queries/0_stateless/01732_explain_syntax_union_query.sql"] | panic when A union B union all C | **Describe the bug**
1. execute SQL: `select 1 from a union select 1 from b union all select 1 from c`
2. server panic
**Does it reproduce on recent release?**
* 21.3.1.1
* 21.2.2.8
**Expected behavior**
SQL should error with message: "Expected ALL or DISTINCT in SelectWithUnion query, because setting (union_default_mode) is empty: While processing SELECT 1 FROM a UNION SELECT 1 FROM b UNION ALL SELECT 1 FROM c"
**Error message and/or stacktrace**
```
2021.02.25 15:18:36.291248 [ 46895 ] {} <Fatal> BaseDaemon: ########################################
2021.02.25 15:18:36.291294 [ 46895 ] {} <Fatal> BaseDaemon: (version 21.2.2.8 (official build), build id: 67D2DA03ADA750F18CEB331C65F50D0F56E33713) (from thread 78379) (no query) Received signal Segmentation fault (11)
2021.02.25 15:18:36.291323 [ 46895 ] {} <Fatal> BaseDaemon: Address: NULL pointer. Access: read. Address not mapped to object.
2021.02.25 15:18:36.291339 [ 46895 ] {} <Fatal> BaseDaemon: Stack trace: 0x11451fff 0x114434a8 0x1148b1bc 0xed45ba5 0xed4408f 0xeb56650 0xeed0c9c 0xeecf7fc 0xf5ca265 0xf5d9ee9 0x11b76baf 0x11b785c1 0x11caf669 0x11cab4ca 0x7f80b67126db 0x7f80b643b71f
2021.02.25 15:18:36.298150 [ 46895 ] {} <Fatal> BaseDaemon: 2. DB::ASTSelectWithUnionQuery::formatQueryImpl(DB::IAST::FormatSettings const&, DB::IAST::FormatState&, DB::IAST::FormatStateStacked) const @ 0x11451fff in /usr/lib/debug/.build-id/67/d2da03ada750f18ceb331c65f50d0f56e33713.debug
2021.02.25 15:18:36.300165 [ 46895 ] {} <Fatal> BaseDaemon: 3. DB::ASTQueryWithOutput::formatImpl(DB::IAST::FormatSettings const&, DB::IAST::FormatState&, DB::IAST::FormatStateStacked) const @ 0x114434a8 in /usr/lib/debug/.build-id/67/d2da03ada750f18ceb331c65f50d0f56e33713.debug
2021.02.25 15:18:36.307065 [ 46895 ] {} <Fatal> BaseDaemon: 4. DB::IAST::formatForErrorMessage() const @ 0x1148b1bc in /usr/lib/debug/.build-id/67/d2da03ada750f18ceb331c65f50d0f56e33713.debug
2021.02.25 15:18:36.311723 [ 46895 ] {} <Fatal> BaseDaemon: 5. DB::InDepthNodeVisitor<DB::OneTypeMatcher<DB::CustomizeASTSelectWithUnionQueryNormalize, &(DB::NeedChild::all(std::__1::shared_ptr<DB::IAST> const&, std::__1::shared_ptr<DB::IAST> const&)), std::__1::shared_ptr<DB::IAST> >, false, std::__1::shared_ptr<DB::IAST> >::visit(std::__1::shared_ptr<DB::IAST>&) @ 0xed45ba5 in /usr/lib/debug/.build-id/67/d2da03ada750f18ceb331c65f50d0f56e33713.debug
2021.02.25 15:18:36.311758 [ 46895 ] {} <Fatal> BaseDaemon: 6. DB::InterpreterSelectWithUnionQuery::InterpreterSelectWithUnionQuery(std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) @ 0xed4408f in /usr/lib/debug/.build-id/67/d2da03ada750f18ceb331c65f50d0f56e33713.debug
2021.02.25 15:18:36.311777 [ 46895 ] {} <Fatal> BaseDaemon: 7. DB::InterpreterFactory::get(std::__1::shared_ptr<DB::IAST>&, DB::Context&, DB::SelectQueryOptions const&) @ 0xeb56650 in /usr/lib/debug/.build-id/67/d2da03ada750f18ceb331c65f50d0f56e33713.debug
2021.02.25 15:18:36.314890 [ 46895 ] {} <Fatal> BaseDaemon: 8. DB::executeQueryImpl(char const*, char const*, DB::Context&, bool, DB::QueryProcessingStage::Enum, bool, DB::ReadBuffer*) @ 0xeed0c9c in /usr/lib/debug/.build-id/67/d2da03ada750f18ceb331c65f50d0f56e33713.debug
2021.02.25 15:18:36.327946 [ 46895 ] {} <Fatal> BaseDaemon: 9. DB::executeQuery(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, DB::Context&, bool, DB::QueryProcessingStage::Enum, bool) @ 0xeecf7fc in /usr/lib/debug/.build-id/67/d2da03ada750f18ceb331c65f50d0f56e33713.debug
2021.02.25 15:18:36.330944 [ 46895 ] {} <Fatal> BaseDaemon: 10. DB::TCPHandler::runImpl() @ 0xf5ca265 in /usr/lib/debug/.build-id/67/d2da03ada750f18ceb331c65f50d0f56e33713.debug
2021.02.25 15:18:36.333015 [ 46895 ] {} <Fatal> BaseDaemon: 11. DB::TCPHandler::run() @ 0xf5d9ee9 in /usr/lib/debug/.build-id/67/d2da03ada750f18ceb331c65f50d0f56e33713.debug
2021.02.25 15:18:36.342141 [ 46895 ] {} <Fatal> BaseDaemon: 12. Poco::Net::TCPServerConnection::start() @ 0x11b76baf in /usr/lib/debug/.build-id/67/d2da03ada750f18ceb331c65f50d0f56e33713.debug
2021.02.25 15:18:36.342165 [ 46895 ] {} <Fatal> BaseDaemon: 13. Poco::Net::TCPServerDispatcher::run() @ 0x11b785c1 in /usr/lib/debug/.build-id/67/d2da03ada750f18ceb331c65f50d0f56e33713.debug
2021.02.25 15:18:36.342447 [ 46895 ] {} <Fatal> BaseDaemon: 14. Poco::PooledThread::run() @ 0x11caf669 in /usr/lib/debug/.build-id/67/d2da03ada750f18ceb331c65f50d0f56e33713.debug
2021.02.25 15:18:36.342672 [ 46895 ] {} <Fatal> BaseDaemon: 15. Poco::ThreadImpl::runnableEntry(void*) @ 0x11cab4ca in /usr/lib/debug/.build-id/67/d2da03ada750f18ceb331c65f50d0f56e33713.debug
2021.02.25 15:18:36.342689 [ 46895 ] {} <Fatal> BaseDaemon: 16. start_thread @ 0x76db in /lib/x86_64-linux-gnu/libpthread-2.27.so
2021.02.25 15:18:36.342785 [ 46895 ] {} <Fatal> BaseDaemon: 17. /build/glibc-S9d2JN/glibc-2.27/misc/../sysdeps/unix/sysv/linux/x86_64/clone.S:97: __GI___clone @ 0x12171f in /usr/lib/debug/lib/x86_64-linux-gnu/libc-2.27.so
2021.02.25 15:18:36.433212 [ 46895 ] {} <Fatal> BaseDaemon: Checksum of the binary: 3B52BD94C585A17D2C45E5ABAABC8124, integrity check passed.
2021.02.25 15:20:09.800886 [ 78267 ] {} <Fatal> Application: Child process was terminated by signal 11.
``` | https://github.com/ClickHouse/ClickHouse/issues/21170 | https://github.com/ClickHouse/ClickHouse/pull/21246 | d9e22ba646d9946a4c3e3abee39a1842b552dfc3 | 8e6fa404c4b6eb618d84411814432e59fc1d9a72 | "2021-02-25T07:22:02Z" | c++ | "2021-03-02T18:37:07Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,167 | ["src/Client/MultiplexedConnections.cpp", "src/Core/Settings.h", "src/Server/TCPHandler.cpp", "src/Server/TCPHandler.h", "tests/queries/0_stateless/01822_async_read_from_socket_crash.reference", "tests/queries/0_stateless/01822_async_read_from_socket_crash.sh"] | Crash 21.2.4.6 | Had the similar problem after upgrade from 20.12.5.14
```
[ch-01] 2021.02.24 20:31:13.845342 [ 17553 ] <Fatal> BaseDaemon: ########################################
[ch-01] 2021.02.24 20:31:13.845469 [ 17553 ] <Fatal> BaseDaemon: (version 21.2.4.6 (official build), build id: 6E2E926515F53BCF094B3D6BD7E9EB65BC5BCE6B) (from thread 10568) (query_id: b03fb6ff-7fe1-400e-bb55-d71b0c611525) Received signal Segmentation fault (11)
[ch-01] 2021.02.24 20:31:13.845530 [ 17553 ] <Fatal> BaseDaemon: Address: 0x90 Access: read. Address not mapped to object.
[ch-01] 2021.02.24 20:31:13.845583 [ 17553 ] <Fatal> BaseDaemon: Stack trace: 0xf518654 0xf518379 0xf525f05 0xf526640 0xe6ad857 0xf63b0ac 0xf63b879 0xf63b14c 0xf63b879 0xf63b14c 0xf63b839 0xf63ed80 0xf6432b6 0x84f6e4f 0x84fa8e3 0x7f6e6c5c9ea5 0x7f6e6c2f28dd
[ch-01] 2021.02.24 20:31:13.845660 [ 17553 ] <Fatal> BaseDaemon: 2. ? @ 0xf518654 in /usr/bin/clickhouse
[ch-01] 2021.02.24 20:31:13.845763 [ 17553 ] <Fatal> BaseDaemon: 3. DB::Connection::receivePacket(std::__1::function<void (Poco::Net::Socket&)>) @ 0xf518379 in /usr/bin/clickhouse
[ch-01] 2021.02.24 20:31:13.845821 [ 17553 ] <Fatal> BaseDaemon: 4. DB::MultiplexedConnections::receivePacketUnlocked(std::__1::function<void (Poco::Net::Socket&)>) @ 0xf525f05 in /usr/bin/clickhouse
[ch-01] 2021.02.24 20:31:13.845886 [ 17553 ] <Fatal> BaseDaemon: 5. DB::MultiplexedConnections::drain() @ 0xf526640 in /usr/bin/clickhouse
[ch-01] 2021.02.24 20:31:13.845969 [ 17553 ] <Fatal> BaseDaemon: 6. DB::RemoteQueryExecutor::finish(std::__1::unique_ptr<DB::RemoteQueryExecutorReadContext, std::__1::default_delete<DB::RemoteQueryExecutorReadContext> >*) @ 0xe6ad857 in /usr/bin/clickhouse
[ch-01] 2021.02.24 20:31:13.846067 [ 17553 ] <Fatal> BaseDaemon: 7. DB::PipelineExecutor::tryAddProcessorToStackIfUpdated(DB::ExecutingGraph::Edge&, std::__1::queue<DB::ExecutingGraph::Node*, std::__1::deque<DB::ExecutingGraph::Node*, std::__1::allocator<DB::ExecutingGraph::Node*> > >&, std::__1::queue<DB::ExecutingGraph::Node*, std::__1::deque<DB::ExecutingGraph::Node*, std::__1::allocator<DB::ExecutingGraph::Node*> > >&, unsigned long) @ 0xf63b0ac in /usr/bin/clickhouse
[ch-01] 2021.02.24 20:31:13.846135 [ 17553 ] <Fatal> BaseDaemon: 8. DB::PipelineExecutor::prepareProcessor(unsigned long, unsigned long, std::__1::queue<DB::ExecutingGraph::Node*, std::__1::deque<DB::ExecutingGraph::Node*, std::__1::allocator<DB::ExecutingGraph::Node*> > >&, std::__1::queue<DB::ExecutingGraph::Node*, std::__1::deque<DB::ExecutingGraph::Node*, std::__1::allocator<DB::ExecutingGraph::Node*> > >&, std::__1::unique_lock<std::__1::mutex>) @ 0xf63b879 in /usr/bin/clickhouse
[ch-01] 2021.02.24 20:31:13.846180 [ 17553 ] <Fatal> BaseDaemon: 9. DB::PipelineExecutor::tryAddProcessorToStackIfUpdated(DB::ExecutingGraph::Edge&, std::__1::queue<DB::ExecutingGraph::Node*, std::__1::deque<DB::ExecutingGraph::Node*, std::__1::allocator<DB::ExecutingGraph::Node*> > >&, std::__1::queue<DB::ExecutingGraph::Node*, std::__1::deque<DB::ExecutingGraph::Node*, std::__1::allocator<DB::ExecutingGraph::Node*> > >&, unsigned long) @ 0xf63b14c in /usr/bin/clickhouse
[ch-01] 2021.02.24 20:31:13.846241 [ 17553 ] <Fatal> BaseDaemon: 10. DB::PipelineExecutor::prepareProcessor(unsigned long, unsigned long, std::__1::queue<DB::ExecutingGraph::Node*, std::__1::deque<DB::ExecutingGraph::Node*, std::__1::allocator<DB::ExecutingGraph::Node*> > >&, std::__1::queue<DB::ExecutingGraph::Node*, std::__1::deque<DB::ExecutingGraph::Node*, std::__1::allocator<DB::ExecutingGraph::Node*> > >&, std::__1::unique_lock<std::__1::mutex>) @ 0xf63b879 in /usr/bin/clickhouse
[ch-01] 2021.02.24 20:31:13.846308 [ 17553 ] <Fatal> BaseDaemon: 11. DB::PipelineExecutor::tryAddProcessorToStackIfUpdated(DB::ExecutingGraph::Edge&, std::__1::queue<DB::ExecutingGraph::Node*, std::__1::deque<DB::ExecutingGraph::Node*, std::__1::allocator<DB::ExecutingGraph::Node*> > >&, std::__1::queue<DB::ExecutingGraph::Node*, std::__1::deque<DB::ExecutingGraph::Node*, std::__1::allocator<DB::ExecutingGraph::Node*> > >&, unsigned long) @ 0xf63b14c in /usr/bin/clickhouse
[ch-01] 2021.02.24 20:31:13.846369 [ 17553 ] <Fatal> BaseDaemon: 12. DB::PipelineExecutor::prepareProcessor(unsigned long, unsigned long, std::__1::queue<DB::ExecutingGraph::Node*, std::__1::deque<DB::ExecutingGraph::Node*, std::__1::allocator<DB::ExecutingGraph::Node*> > >&, std::__1::queue<DB::ExecutingGraph::Node*, std::__1::deque<DB::ExecutingGraph::Node*, std::__1::allocator<DB::ExecutingGraph::Node*> > >&, std::__1::unique_lock<std::__1::mutex>) @ 0xf63b839 in /usr/bin/clickhouse
[ch-01] 2021.02.24 20:31:13.846439 [ 17553 ] <Fatal> BaseDaemon: 13. DB::PipelineExecutor::executeStepImpl(unsigned long, unsigned long, std::__1::atomic<bool>*) @ 0xf63ed80 in /usr/bin/clickhouse
[ch-01] 2021.02.24 20:31:13.846485 [ 17553 ] <Fatal> BaseDaemon: 14. ? @ 0xf6432b6 in /usr/bin/clickhouse
[ch-01] 2021.02.24 20:31:13.846562 [ 17553 ] <Fatal> BaseDaemon: 15. ThreadPoolImpl<std::__1::thread>::worker(std::__1::__list_iterator<std::__1::thread, void*>) @ 0x84f6e4f in /usr/bin/clickhouse
[ch-01] 2021.02.24 20:31:13.846622 [ 17553 ] <Fatal> BaseDaemon: 16. ? @ 0x84fa8e3 in /usr/bin/clickhouse
[ch-01] 2021.02.24 20:31:13.846708 [ 17553 ] <Fatal> BaseDaemon: 17. start_thread @ 0x7ea5 in /usr/lib64/libpthread-2.17.so
[ch-01] 2021.02.24 20:31:13.846796 [ 17553 ] <Fatal> BaseDaemon: 18. __clone @ 0xfe8dd in /usr/lib64/libc-2.17.so
[ch-01] 2021.02.24 20:31:14.053143 [ 17553 ] <Fatal> BaseDaemon: Checksum of the binary: 88E22F0584BA91872F2E9BE493E6985B, integrity check passed.
```
_Originally posted by @chyy in https://github.com/ClickHouse/ClickHouse/issues/8997#issuecomment-785538830_ | https://github.com/ClickHouse/ClickHouse/issues/21167 | https://github.com/ClickHouse/ClickHouse/pull/23309 | 9ec6fd19436cc0a7841be23cf77774f6105c85b3 | 44112587d414cb9be64734ad16e52b03e06ad484 | "2021-02-25T04:11:07Z" | c++ | "2021-04-21T05:47:17Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,140 | ["src/Processors/Formats/Impl/ConstantExpressionTemplate.cpp", "src/Processors/Formats/Impl/ConstantExpressionTemplate.h", "src/Processors/Formats/Impl/ValuesBlockInputFormat.cpp", "tests/queries/0_stateless/01746_lc_values_format_bug.reference", "tests/queries/0_stateless/01746_lc_values_format_bug.sql"] | Version 21.1 Code: 49. DB::Exception: Bad cast from type DB::ColumnString to DB::ColumnLowCardinality: | **Describe the issue**
Can't insert `String` data to column with `LowCardinality` type.
Starting from 21.1 this query fails
**How to reproduce**
```sql
CREATE TABLE default.lc_test
(
`id` LowCardinality(String)
)
ENGINE = MergeTree
PARTITION BY tuple()
ORDER BY id;
Ok.
0 rows in set. Elapsed: 0.003 sec.
insert into lc_test values (toString('a'));
Exception on client:
Code: 49. DB::Exception: Bad cast from type DB::ColumnString to DB::ColumnLowCardinality: data for INSERT was parsed from query
```
**Additional context**
related to issue https://github.com/DarkWanderer/ClickHouse.Client/issues/66
version 20.12 ok | https://github.com/ClickHouse/ClickHouse/issues/21140 | https://github.com/ClickHouse/ClickHouse/pull/21357 | d305b233389fcd0c044d4e291286455fd6e3ea6b | ee22eeea6cf62795701d542bd548f4bfe2c4fd97 | "2021-02-24T10:52:57Z" | c++ | "2021-03-02T10:12:12Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,137 | ["src/Interpreters/HashJoin.cpp", "src/Interpreters/IJoin.h", "src/Interpreters/MergeJoin.cpp", "src/Interpreters/join_common.cpp", "src/Interpreters/join_common.h", "tests/queries/0_stateless/01637_nullable_fuzz3.reference", "tests/queries/0_stateless/01637_nullable_fuzz3.sql"] | Segfault in FULL JOIN | https://clickhouse-test-reports.s3.yandex.net/21020/2ced21c837006053542b9f04c338faebf504f413/fuzzer_asan/server.log | https://github.com/ClickHouse/ClickHouse/issues/21137 | https://github.com/ClickHouse/ClickHouse/pull/21248 | 63b95c7451c70f35d3692b88340d87c4a0e4649d | df728dc4ba5cae45958a1c5ee96d49049f1d6919 | "2021-02-24T10:43:25Z" | c++ | "2021-02-27T08:31:02Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,118 | ["contrib/cppkafka", "src/Storages/Kafka/ReadBufferFromKafkaConsumer.cpp", "src/Storages/Kafka/ReadBufferFromKafkaConsumer.h", "tests/integration/test_storage_kafka/test.py"] | Having consumer group member failover problem in ClickHouse Kafka engine | ## Environment
* ClickHouse server version: 21.2.4 revision 54447
## Background
I m in the process of setting up a 2-node ClickHouse cluster, each node is with identical tables (as follows) for fetching data from Kafka topic.
```
CREATE TABLE `queue_05` (
`id` UInt64,
...
)
ENGINE = Kafka()
SETTINGS
kafka_broker_list = 'kafka01:9092,kafka02:9092,kafka03:9092',
kafka_topic_list = 'topic03',
kafka_group_name = 'g03',
kafka_client_id = 'c03',
kafka_format = 'JSONEachRow',
kafka_num_consumers = 1
```
```
CREATE TABLE `table_03` (
`id` UInt64,
...
)
ENGINE = ReplicatedReplacingMergeTree(
'/clickhouse/tables/{shard}/table_03',
'{replica}',
updated_at
)
PARTITION BY toYYYYMM(`time`)
PRIMARY KEY id
```
```
CREATE MATERIALIZED VIEW `mv_03` TO `table_03`
AS SELECT * FROM `queue_05`;
```
The Kafka topic `topic03` is with single partition. The ClickHouse tables `queue_05` in db01, db02 are in the same consumer group `g03` and are expected to work for failover purpose.
## Problem
When both tables `queue_05` in db01, db02 are attached, one of the table fetches data from single partition of topic `topic03`, the other table are in standby; when one node is down or one of the tables `queue_05` is detached, consumer group `g03` is then rebalancing and find no active members after a while, no failover happens.
Here is the log snippet of clickhouse-server.log in db02, right after I manually detach table `queue_05` in db01.
```
2021.02.24 11:43:46.110365 [ 1023 ] {} <Trace> StorageKafka (queue_05): Nothing to commit.
2021.02.24 11:43:46.110429 [ 1023 ] {} <Trace> StorageKafka (queue_05): Stream(s) stalled. Reschedule.
2021.02.24 11:43:46.610572 [ 1023 ] {} <Debug> StorageKafka (queue_05): Started streaming to 1 attached views
2021.02.24 11:43:46.611817 [ 1271 ] {} <Debug> StorageKafka (queue_05): [rdk:CGRPOP] [thrd:main]: Group "g03" received op GET_SUBSCRIPTION in state up (join-state wait-assign-call)
2021.02.24 11:43:46.611916 [ 1271 ] {} <Debug> StorageKafka (queue_05): [rdk:CGRPOP] [thrd:main]: Group "g03" received op GET_SUBSCRIPTION in state up (join-state wait-assign-call)
2021.02.24 11:43:46.611949 [ 1023 ] {} <Trace> StorageKafka (queue_05): Already subscribed to topics: [topic03]
2021.02.24 11:43:46.611959 [ 1023 ] {} <Trace> StorageKafka (queue_05): Already assigned to: [ ]
2021.02.24 11:43:46.611989 [ 1271 ] {} <Debug> StorageKafka (queue_05): [rdk:CGRPOP] [thrd:main]: Group "g03" received op GET_SUBSCRIPTION in state up (join-state wait-assign-call)
2021.02.24 11:43:46.662303 [ 1023 ] {} <Warning> StorageKafka (queue_05): Can't get assignment. It can be caused by some issue with consumer group (not enough partitions?). Will keep trying.
2021.02.24 11:43:46.662403 [ 1271 ] {} <Debug> StorageKafka (queue_05): [rdk:CGRPOP] [thrd:main]: Group "g03" received op GET_ASSIGNMENT in state up (join-state wait-assign-call)
2021.02.24 11:43:46.662465 [ 1023 ] {} <Trace> StorageKafka (queue_05): Nothing to commit.
2021.02.24 11:43:46.662582 [ 1023 ] {} <Trace> StorageKafka (queue_05): Stream(s) stalled. Reschedule.
2021.02.24 11:43:47.162758 [ 1023 ] {} <Debug> StorageKafka (queue_05): Started streaming to 1 attached views
2021.02.24 11:43:47.163558 [ 1271 ] {} <Debug> StorageKafka (queue_05): [rdk:CGRPOP] [thrd:main]: Group "g03" received op GET_SUBSCRIPTION in state up (join-state wait-assign-call)
2021.02.24 11:43:47.163614 [ 1271 ] {} <Debug> StorageKafka (queue_05): [rdk:CGRPOP] [thrd:main]: Group "g03" received op GET_SUBSCRIPTION in state up (join-state wait-assign-call)
2021.02.24 11:43:47.163642 [ 1023 ] {} <Trace> StorageKafka (queue_05): Already subscribed to topics: [topic03]
2021.02.24 11:43:47.163653 [ 1023 ] {} <Trace> StorageKafka (queue_05): Already assigned to: [ ]
2021.02.24 11:43:47.163680 [ 1271 ] {} <Debug> StorageKafka (queue_05): [rdk:CGRPOP] [thrd:main]: Group "g03" received op GET_SUBSCRIPTION in state up (join-state wait-assign-call)
2021.02.24 11:43:47.213860 [ 1023 ] {} <Warning> StorageKafka (queue_05): Can't get assignment. It can be caused by some issue with consumer group (not enough partitions?). Will keep trying.
2021.02.24 11:43:47.213967 [ 1271 ] {} <Debug> StorageKafka (queue_05): [rdk:CGRPOP] [thrd:main]: Group "g03" received op GET_ASSIGNMENT in state up (join-state wait-assign-call)
2021.02.24 11:43:47.214040 [ 1023 ] {} <Trace> StorageKafka (queue_05): Nothing to commit.
2021.02.24 11:43:47.214134 [ 1023 ] {} <Trace> StorageKafka (queue_05): Stream(s) stalled. Reschedule.
2021.02.24 11:43:47.714289 [ 1023 ] {} <Debug> StorageKafka (queue_05): Started streaming to 1 attached views
2021.02.24 11:43:47.715333 [ 1271 ] {} <Debug> StorageKafka (queue_05): [rdk:CGRPOP] [thrd:main]: Group "g03" received op GET_SUBSCRIPTION in state up (join-state wait-assign-call)
```
With the same Kafka broker settings, I setup another consumer group with 2 members (by `kafka-console-consumer.sh`) to consume data from single partition of topic `topic03`, when one member is down, consumer group rebalances and assigns the topic partition to the rest member successfully.
## Question
I guess I might have wrong configurations in ClickHouse and find no clue myself. Do you have idea of Kafka consumer group failover issue in my case? Any comment is appreciated.
| https://github.com/ClickHouse/ClickHouse/issues/21118 | https://github.com/ClickHouse/ClickHouse/pull/21267 | d0aa387e64b4ec70b6c8ad7276b98cd1afe08c42 | 77721734ed1d49f3923da55c00f3c6f0319261f1 | "2021-02-24T04:14:41Z" | c++ | "2021-06-13T22:42:42Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,092 | ["src/Parsers/ASTWindowDefinition.cpp"] | Wrong SQL echo in window functions | ```sql
RANGE BETWEEN UNBOUNDED PRECEDING AND UNBOUNDED FOLLOWING
VS
RANGE BETWEEN UNBOUNDED PRECEDING AND UNBOUNDED PRECEDING
select product_name, price, group_name, round(avg0), round(avg1)
from (
SELECT
product_name,
price,
group_name,
avg(price) OVER (PARTITION BY group_name ORDER BY price) avg0,
avg(price) OVER (PARTITION BY group_name ORDER BY
price RANGE BETWEEN UNBOUNDED PRECEDING AND UNBOUNDED FOLLOWING) avg1
FROM products INNER JOIN product_groups USING (group_id)) t
order by group_name, product_name, price;
SELECT
product_name,
price,
group_name,
round(avg0),
round(avg1)
FROM
(
SELECT
product_name,
price,
group_name,
avg(price) OVER (PARTITION BY group_name ORDER BY price ASC) AS avg0,
avg(price) OVER (PARTITION BY group_name ORDER BY price ASC RANGE BETWEEN UNBOUNDED PRECEDING AND UNBOUNDED PRECEDING) AS avg1
FROM products
INNER JOIN product_groups USING (group_id)
) AS t
ORDER BY
group_name ASC,
product_name ASC,
price ASC
``` | https://github.com/ClickHouse/ClickHouse/issues/21092 | https://github.com/ClickHouse/ClickHouse/pull/21572 | e27715e55e471dc4d7f825eb4097b468a9a4a451 | b399f80b7e8b140ebcd552e443c8f537b5353bf3 | "2021-02-23T00:40:07Z" | c++ | "2021-03-10T10:38:39Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,059 | ["src/Interpreters/ExpressionActions.cpp", "tests/queries/0_stateless/01800_log_nested.reference", "tests/queries/0_stateless/01800_log_nested.sql"] | Logical error: no information about file (part of nested column) in StorageLog | https://clickhouse-test-reports.s3.yandex.net/20599/0a62f95bbe380abe8d8846ef9690b8a18c6a762b/fuzzer_debug/report.html#fail1 | https://github.com/ClickHouse/ClickHouse/issues/21059 | https://github.com/ClickHouse/ClickHouse/pull/22654 | 32cf4e378edddebc1b2c6df533bb88cadc376eff | c5354885a6fa9deefa0fa185f14703fbcfa76295 | "2021-02-22T10:37:56Z" | c++ | "2021-04-05T21:34:58Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,034 | ["src/Functions/FunctionsConversion.h", "tests/queries/0_stateless/01691_DateTime64_clamp.reference", "tests/queries/0_stateless/01691_DateTime64_clamp.sql", "tests/queries/0_stateless/01734_datetime64_from_float.reference", "tests/queries/0_stateless/01734_datetime64_from_float.sql"] | Unreleased: change in behaviour of converting Float to DateTime64 | 21.2:
```
milovidov-desktop :) SELECT CAST(1111111111.222 AS DateTime64(3))
SELECT cast(1111111111.222, 'DateTime64(3)')
Query id: d10c8623-5c74-4a38-b535-a99f6af4d28d
ββcast(1111111111.222, 'DateTime64(3)')ββ
β 2005-03-18 04:58:31.222 β
βββββββββββββββββββββββββββββββββββββββββ
```
master:
```
milovidov-desktop :) SELECT CAST(1111111111.222 AS DateTime64(3))
SELECT cast(1111111111.222, 'DateTime64(3)')
Query id: cb4af967-a4ae-4df5-89ba-234d68675f93
ββcast(1111111111.222, 'DateTime64(3)')ββ
β 2005-03-18 04:58:31.000 β
βββββββββββββββββββββββββββββββββββββββββ
``` | https://github.com/ClickHouse/ClickHouse/issues/21034 | https://github.com/ClickHouse/ClickHouse/pull/21050 | 9f9b862a477e545288d3d67ca36a08f0c39d012f | 8b82c7ea0c6079a135dfbaa6b1b755579ae8beb1 | "2021-02-21T13:03:27Z" | c++ | "2021-02-22T10:12:09Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,032 | ["src/Columns/ColumnMap.cpp", "src/DataTypes/DataTypeTuple.cpp", "src/Interpreters/convertFieldToType.cpp", "src/Processors/Formats/Impl/ConstantExpressionTemplate.cpp", "src/Processors/Formats/Impl/ValuesBlockInputFormat.cpp", "src/Processors/Formats/Impl/ValuesBlockInputFormat.h", "tests/queries/0_stateless/01550_create_map_type.reference", "tests/queries/0_stateless/01550_create_map_type.sql", "tests/queries/0_stateless/01715_tuple_insert_null_as_default.reference", "tests/queries/0_stateless/01715_tuple_insert_null_as_default.sql"] | Map Type: can't insert negative int values | **Describe the bug**
Can't insert negative values into `Map(Int8, Int8)` column either as keys or values.
The same when trying to insert negative values into `Map(Int8, Int16)`, `Map(Int8, Int32)` or `Map(Int8, Int64)`.
Similar problem when trying to insert negative keys into `Map(Int16, Int8)`, `Map(Int32, Int8)` or `Map(Int64, Int8)`.
```
Feb 21,2021 7:49:40 β₯ Example Int8
Check what values we can insert into map type column with value integer.
Requirements
RQ.SRS-018.ClickHouse.Map.DataType.Value.Integer
version 1.0
Arguments
type
Map(Int8, Int8)
data
('2020-01-01', map(1,127,2,0,3,-128))
output
{"d":"2020-01-01","m":{1:127,2:0,3:-128}}
Feb 21,2021 7:49:40 β₯ Given table definition with Map(Int8, Int8), flags:MANDATORY
302us β₯β€ OK table definition with Map(Int8, Int8), /map type/tests/table map with value integer/Int8/table definition with Map(Int8, Int8)
Feb 21,2021 7:49:40 β₯ And I create a table, flags:MANDATORY
CREATE TABLE {name} (d DATE, m Map(Int8, Int8)) ENGINE = MergeTree() PARTITION BY m ORDER BY d
Feb 21,2021 7:49:40 β₯ And I have a table_map_with_value_integer_43276a40_7443_11eb_869f_096b24b409b0 table, flags:MANDATORY
Feb 21,2021 7:49:40 β₯ By executing command
echo -e "CREATE TABLE table_map_with_value_integer_43276a40_7443_11eb_869f_096b24b409b0 (d DATE, m Map(Int8, Int8)) ENGINE = MergeTree() PARTITION BY m ORDER BY d" | clickhouse client -n --allow_experimental_map_type "1"
3ms [clickhouse1] bash# echo -e "CREATE TABLE table_map_with_value_integer_43276a40_7443_11eb_869f_096b24b409b0 (d DATE, m Map(Int8, Int8)) ENGINE = MergeTree() PARTITION BY m ORDER BY d" | clickhouse client -n --allow_experimental_map_type "1"
41ms [clickhouse1] bash# echo $?
41ms [clickhouse1] 0
42ms [clickhouse1] bash#
42ms β₯β€ OK executing command, /map type/tests/table map with value integer/Int8/I create a table/I have a table_map_with_value_integer_43276a40_7443_11eb_869f_096b24b409b0 table/executing command
Feb 21,2021 7:49:40 β₯ Then check if output has exception
829us β₯β€ OK check if output has exception, /map type/tests/table map with value integer/Int8/I create a table/I have a table_map_with_value_integer_43276a40_7443_11eb_869f_096b24b409b0 table/check if output has exception
44ms β₯β€ OK I have a table_map_with_value_integer_43276a40_7443_11eb_869f_096b24b409b0 table, /map type/tests/table map with value integer/Int8/I create a table/I have a table_map_with_value_integer_43276a40_7443_11eb_869f_096b24b409b0 table
44ms β₯β€ OK I create a table, /map type/tests/table map with value integer/Int8/I create a table
Feb 21,2021 7:49:40 β₯ When I insert data
('2020-01-01', map(1,127,2,0,3,-128))
Feb 21,2021 7:49:40 β₯ By executing command
echo -e "INSERT INTO table_map_with_value_integer_43276a40_7443_11eb_869f_096b24b409b0 VALUES ('2020-01-01', map(1,127,2,0,3,-128))" | clickhouse client -n --allow_experimental_map_type "1"
5ms [clickhouse1] bash# echo -e "INSERT INTO table_map_with_value_integer_43276a40_7443_11eb_869f_096b24b409b0 VALUES ('2020-01-01', map(1,127,2,0,3,-128))" | clickhouse client -n --allow_experimental_map_type "1"
50ms [clickhouse1] Error on processing query 'INSERT INTO table_map_with_value_integer_43276a40_7443_11eb_869f_096b24b409b0 VALUES ('2020-01-01', map(1,127,2,0,3,-128))':
51ms [clickhouse1] Code: 53, e.displayText() = DB::Exception: Type mismatch in IN or VALUES section. Expected: Map(Int8,Int8). Got: Map: data for INSERT was parsed from query, Stack trace (when copying this message, always include the lines below):
51ms [clickhouse1]
51ms [clickhouse1] 0. ? @ 0xef62fae in /usr/bin/clickhouse
51ms [clickhouse1] 1. DB::convertFieldToType(DB::Field const&, DB::IDataType const&, DB::IDataType const*) @ 0xef61d24 in /usr/bin/clickhouse
51ms [clickhouse1] 2. DB::ValuesBlockInputFormat::parseExpression(DB::IColumn&, unsigned long) @ 0xf7f274b in /usr/bin/clickhouse
51ms [clickhouse1] 3. DB::ValuesBlockInputFormat::readRow(std::__1::vector<COW<DB::IColumn>::mutable_ptr<DB::IColumn>, std::__1::allocator<COW<DB::IColumn>::mutable_ptr<DB::IColumn> > >&, unsigned long) @ 0xf7f0398 in /usr/bin/clickhouse
51ms [clickhouse1] 4. DB::ValuesBlockInputFormat::generate() @ 0xf7ef73c in /usr/bin/clickhouse
51ms [clickhouse1] 5. DB::ISource::tryGenerate() @ 0xf6df1b5 in /usr/bin/clickhouse
51ms [clickhouse1] 6. DB::ISource::work() @ 0xf6deeca in /usr/bin/clickhouse
51ms [clickhouse1] 7. DB::InputStreamFromInputFormat::readImpl() @ 0xce6517f in /usr/bin/clickhouse
51ms [clickhouse1] 8. DB::IBlockInputStream::read() @ 0xe710385 in /usr/bin/clickhouse
51ms [clickhouse1] 9. DB::AsynchronousBlockInputStream::calculate() @ 0xe70c701 in /usr/bin/clickhouse
51ms [clickhouse1] 10. ? @ 0xe70cf77 in /usr/bin/clickhouse
51ms [clickhouse1] 11. ThreadPoolImpl<ThreadFromGlobalPool>::worker(std::__1::__list_iterator<ThreadFromGlobalPool, void*>) @ 0x8528a48 in /usr/bin/clickhouse
52ms [clickhouse1] 12. ThreadFromGlobalPool::ThreadFromGlobalPool<void ThreadPoolImpl<ThreadFromGlobalPool>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()>(void&&, void ThreadPoolImpl<ThreadFromGlobalPool>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()&&...)::'lambda'()::operator()() @ 0x852a9ff in /usr/bin/clickhouse
52ms [clickhouse1] 13. ThreadPoolImpl<std::__1::thread>::worker(std::__1::__list_iterator<std::__1::thread, void*>) @ 0x852601f in /usr/bin/clickhouse
52ms [clickhouse1] 14. ? @ 0x8529ab3 in /usr/bin/clickhouse
52ms [clickhouse1] 15. start_thread @ 0x9609 in /usr/lib/x86_64-linux-gnu/libpthread-2.31.so
52ms [clickhouse1] 16. clone @ 0x122293 in /usr/lib/x86_64-linux-gnu/libc-2.31.so
52ms [clickhouse1] (version 21.3.1.5944 (official build))
56ms [clickhouse1] bash# echo $?
56ms [clickhouse1] 53
57ms [clickhouse1] bash#
```
**Expected behavior**
It should work.
| https://github.com/ClickHouse/ClickHouse/issues/21032 | https://github.com/ClickHouse/ClickHouse/pull/20541 | 427e5f295cf0f88fc1ea0de2722f016d0998cfc7 | 7bbc4e013af6e008c53630fdeca7b6d61b4f9c8f | "2021-02-21T12:54:57Z" | c++ | "2021-02-24T09:00:48Z" |
closed | ClickHouse/ClickHouse | https://github.com/ClickHouse/ClickHouse | 21,031 | ["src/Columns/ColumnMap.cpp", "src/DataTypes/DataTypeTuple.cpp", "src/Interpreters/convertFieldToType.cpp", "src/Processors/Formats/Impl/ConstantExpressionTemplate.cpp", "src/Processors/Formats/Impl/ValuesBlockInputFormat.cpp", "src/Processors/Formats/Impl/ValuesBlockInputFormat.h", "tests/queries/0_stateless/01550_create_map_type.reference", "tests/queries/0_stateless/01550_create_map_type.sql", "tests/queries/0_stateless/01715_tuple_insert_null_as_default.reference", "tests/queries/0_stateless/01715_tuple_insert_null_as_default.sql"] | Map Type: can't insert UInt256 value | Can't insert `115792089237316195423570985008687907853269984665640564039457584007913129639935` value
into `Map(Int8, UInt256)` column.
```
Feb 21,2021 7:42:41 β₯ Example UInt256
Check what values we can insert into map type column with value integer.
Requirements
RQ.SRS-018.ClickHouse.Map.DataType.Value.Integer
version 1.0
Arguments
type
Map(Int8, UInt256)
data
('2020-01-01', map(1,0,2,115792089237316195423570985008687907853269984665640564039457584007913129639935))
output
{"d":"2020-01-01","m":{1:"0",2:"115792089237316195423570985008687907853269984665640564039457584007913129639935"}}
Feb 21,2021 7:42:41 β₯ Given table definition with Map(Int8, UInt256), flags:MANDATORY
400us β₯β€ OK table definition with Map(Int8, UInt256), /map type/tests/table map with value integer/UInt256/table definition with Map(Int8, UInt256)
Feb 21,2021 7:42:41 β₯ And I create a table, flags:MANDATORY
CREATE TABLE {name} (d DATE, m Map(Int8, UInt256)) ENGINE = MergeTree() PARTITION BY m ORDER BY d
Feb 21,2021 7:42:41 β₯ And I have a table_map_with_value_integer_49ab6e1c_7442_11eb_869f_096b24b409b0 table, flags:MANDATORY
Feb 21,2021 7:42:41 β₯ By executing command
echo -e "CREATE TABLE table_map_with_value_integer_49ab6e1c_7442_11eb_869f_096b24b409b0 (d DATE, m Map(Int8, UInt256)) ENGINE = MergeTree() PARTITION BY m ORDER BY d" | clickhouse client -n --allow_experimental_map_type "1"
2ms [clickhouse1] bash# echo -e "CREATE TABLE table_map_with_value_integer_49ab6e1c_7442_11eb_869f_096b24b409b0 (d DATE, m Map(Int8, UInt256)) ENGINE = MergeTree() PARTITION BY m ORDER BY d" | clickhouse client -n --allow_experimental_map_type "1"
37ms [clickhouse1] bash# echo $?
37ms [clickhouse1] 0
37ms [clickhouse1] bash#
37ms β₯β€ OK executing command, /map type/tests/table map with value integer/UInt256/I create a table/I have a table_map_with_value_integer_49ab6e1c_7442_11eb_869f_096b24b409b0 table/executing command
Feb 21,2021 7:42:41 β₯ Then check if output has exception
482us β₯β€ OK check if output has exception, /map type/tests/table map with value integer/UInt256/I create a table/I have a table_map_with_value_integer_49ab6e1c_7442_11eb_869f_096b24b409b0 table/check if output has exception
38ms β₯β€ OK I have a table_map_with_value_integer_49ab6e1c_7442_11eb_869f_096b24b409b0 table, /map type/tests/table map with value integer/UInt256/I create a table/I have a table_map_with_value_integer_49ab6e1c_7442_11eb_869f_096b24b409b0 table
39ms β₯β€ OK I create a table, /map type/tests/table map with value integer/UInt256/I create a table
Feb 21,2021 7:42:41 β₯ When I insert data
('2020-01-01', map(1,0,2,115792089237316195423570985008687907853269984665640564039457584007913129639935))
Feb 21,2021 7:42:41 β₯ By executing command
echo -e "INSERT INTO table_map_with_value_integer_49ab6e1c_7442_11eb_869f_096b24b409b0 VALUES ('2020-01-01', map(1,0,2,115792089237316195423570985008687907853269984665640564039457584007913129639935))" | clickhouse client -n --allow_experimental_map_type "1"
2ms [clickhouse1] bash# echo -e "INSERT INTO table_map_with_value_integer_49ab6e1c_7442_11eb_869f_096b24b409b0 VALUES ('2020-01-01', map(1,0,2,115792089237316195423570985008687907853269984665640564039457584007913129639935))" | clickhouse client -n --allow_experimental_map_type "1"
59ms [clickhouse1] Error on processing query 'INSERT INTO table_map_with_value_integer_49ab6e1c_7442_11eb_869f_096b24b409b0 VALUES ('2020-01-01', map(1,0,2,115792089237316195423570985008687907853269984665640564039457584007913129639935))':
68ms [clickhouse1] Code: 53, e.displayText() = DB::Exception: Type mismatch in IN or VALUES section. Expected: Map(Int8,UInt256). Got: Map: data for INSERT was parsed from query, Stack trace (when copying this message, always include the lines below):
68ms [clickhouse1]
68ms [clickhouse1] 0. ? @ 0xef62fae in /usr/bin/clickhouse
68ms [clickhouse1] 1. DB::convertFieldToType(DB::Field const&, DB::IDataType const&, DB::IDataType const*) @ 0xef61d24 in /usr/bin/clickhouse
68ms [clickhouse1] 2. DB::ValuesBlockInputFormat::parseExpression(DB::IColumn&, unsigned long) @ 0xf7f274b in /usr/bin/clickhouse
68ms [clickhouse1] 3. DB::ValuesBlockInputFormat::readRow(std::__1::vector<COW<DB::IColumn>::mutable_ptr<DB::IColumn>, std::__1::allocator<COW<DB::IColumn>::mutable_ptr<DB::IColumn> > >&, unsigned long) @ 0xf7f0398 in /usr/bin/clickhouse
68ms [clickhouse1] 4. DB::ValuesBlockInputFormat::generate() @ 0xf7ef73c in /usr/bin/clickhouse
68ms [clickhouse1] 5. DB::ISource::tryGenerate() @ 0xf6df1b5 in /usr/bin/clickhouse
69ms [clickhouse1] 6. DB::ISource::work() @ 0xf6deeca in /usr/bin/clickhouse
69ms [clickhouse1] 7. DB::InputStreamFromInputFormat::readImpl() @ 0xce6517f in /usr/bin/clickhouse
69ms [clickhouse1] 8. DB::IBlockInputStream::read() @ 0xe710385 in /usr/bin/clickhouse
69ms [clickhouse1] 9. DB::AsynchronousBlockInputStream::calculate() @ 0xe70c701 in /usr/bin/clickhouse
69ms [clickhouse1] 10. ? @ 0xe70cf77 in /usr/bin/clickhouse
69ms [clickhouse1] 11. ThreadPoolImpl<ThreadFromGlobalPool>::worker(std::__1::__list_iterator<ThreadFromGlobalPool, void*>) @ 0x8528a48 in /usr/bin/clickhouse
69ms [clickhouse1] 12. ThreadFromGlobalPool::ThreadFromGlobalPool<void ThreadPoolImpl<ThreadFromGlobalPool>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()>(void&&, void ThreadPoolImpl<ThreadFromGlobalPool>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()&&...)::'lambda'()::operator()() @ 0x852a9ff in /usr/bin/clickhouse
69ms [clickhouse1] 13. ThreadPoolImpl<std::__1::thread>::worker(std::__1::__list_iterator<std::__1::thread, void*>) @ 0x852601f in /usr/bin/clickhouse
69ms [clickhouse1] 14. ? @ 0x8529ab3 in /usr/bin/clickhouse
69ms [clickhouse1] 15. start_thread @ 0x9609 in /usr/lib/x86_64-linux-gnu/libpthread-2.31.so
69ms [clickhouse1] 16. clone @ 0x122293 in /usr/lib/x86_64-linux-gnu/libc-2.31.so
69ms [clickhouse1] (version 21.3.1.5944 (official build))
72ms [clickhouse1] bash# echo $?
72ms [clickhouse1] 53
73ms [clickhouse1] bash#
```
Similar when trying to insert the same value as the key into `Map(UInt256, UInt8)` column
```
Feb 21,2021 7:46:05 β₯ Example UInt256
Check what values we can insert into map type column with key integer.
Requirements
RQ.SRS-018.ClickHouse.Map.DataType.Key.Integer
version 1.0
Arguments
type
Map(UInt256, Int8)
data
('2020-01-01', map(0,1,115792089237316195423570985008687907853269984665640564039457584007913129639935,1))
output
{"d":"2020-01-01","m":{"0":1,"115792089237316195423570985008687907853269984665640564039457584007913129639935":1}}
Feb 21,2021 7:46:05 β₯ Given table definition with Map(UInt256, Int8), flags:MANDATORY
414us β₯β€ OK table definition with Map(UInt256, Int8), /map type/tests/table map with key integer/UInt256/table definition with Map(UInt256, Int8)
Feb 21,2021 7:46:05 β₯ And I create a table, flags:MANDATORY
CREATE TABLE {name} (d DATE, m Map(UInt256, Int8)) ENGINE = MergeTree() PARTITION BY m ORDER BY d
Feb 21,2021 7:46:05 β₯ And I have a table_map_with_key_integer_c318542c_7442_11eb_869f_096b24b409b0 table, flags:MANDATORY
Feb 21,2021 7:46:05 β₯ By executing command
echo -e "CREATE TABLE table_map_with_key_integer_c318542c_7442_11eb_869f_096b24b409b0 (d DATE, m Map(UInt256, Int8)) ENGINE = MergeTree() PARTITION BY m ORDER BY d" | clickhouse client -n --allow_experimental_map_type "1"
3ms [clickhouse1] bash# echo -e "CREATE TABLE table_map_with_key_integer_c318542c_7442_11eb_869f_096b24b409b0 (d DATE, m Map(UInt256, Int8)) ENGINE = MergeTree() PARTITION BY m ORDER BY d" | clickhouse client -n --allow_experimental_map_type "1"
40ms [clickhouse1] bash# echo $?
41ms [clickhouse1] 0
41ms [clickhouse1] bash#
41ms β₯β€ OK executing command, /map type/tests/table map with key integer/UInt256/I create a table/I have a table_map_with_key_integer_c318542c_7442_11eb_869f_096b24b409b0 table/executing command
Feb 21,2021 7:46:05 β₯ Then check if output has exception
591us β₯β€ OK check if output has exception, /map type/tests/table map with key integer/UInt256/I create a table/I have a table_map_with_key_integer_c318542c_7442_11eb_869f_096b24b409b0 table/check if output has exception
43ms β₯β€ OK I have a table_map_with_key_integer_c318542c_7442_11eb_869f_096b24b409b0 table, /map type/tests/table map with key integer/UInt256/I create a table/I have a table_map_with_key_integer_c318542c_7442_11eb_869f_096b24b409b0 table
43ms β₯β€ OK I create a table, /map type/tests/table map with key integer/UInt256/I create a table
Feb 21,2021 7:46:05 β₯ When I insert data
('2020-01-01', map(0,1,115792089237316195423570985008687907853269984665640564039457584007913129639935,1))
Feb 21,2021 7:46:05 β₯ By executing command
echo -e "INSERT INTO table_map_with_key_integer_c318542c_7442_11eb_869f_096b24b409b0 VALUES ('2020-01-01', map(0,1,115792089237316195423570985008687907853269984665640564039457584007913129639935,1))" | clickhouse client -n --allow_experimental_map_type "1"
2ms [clickhouse1] bash# echo -e "INSERT INTO table_map_with_key_integer_c318542c_7442_11eb_869f_096b24b409b0 VALUES ('2020-01-01', map(0,1,115792089237316195423570985008687907853269984665640564039457584007913129639935,1))" | clickhouse client -n --allow_experimental_map_type "1"
52ms [clickhouse1] Error on processing query 'INSERT INTO table_map_with_key_integer_c318542c_7442_11eb_869f_096b24b409b0 VALUES ('2020-01-01', map(0,1,115792089237316195423570985008687907853269984665640564039457584007913129639935,1))':
52ms [clickhouse1] Code: 53, e.displayText() = DB::Exception: Type mismatch in IN or VALUES section. Expected: Map(UInt256,Int8). Got: Map: data for INSERT was parsed from query, Stack trace (when copying this message, always include the lines below):
52ms [clickhouse1]
52ms [clickhouse1] 0. ? @ 0xef62fae in /usr/bin/clickhouse
52ms [clickhouse1] 1. DB::convertFieldToType(DB::Field const&, DB::IDataType const&, DB::IDataType const*) @ 0xef61d24 in /usr/bin/clickhouse
52ms [clickhouse1] 2. DB::ValuesBlockInputFormat::parseExpression(DB::IColumn&, unsigned long) @ 0xf7f274b in /usr/bin/clickhouse
52ms [clickhouse1] 3. DB::ValuesBlockInputFormat::readRow(std::__1::vector<COW<DB::IColumn>::mutable_ptr<DB::IColumn>, std::__1::allocator<COW<DB::IColumn>::mutable_ptr<DB::IColumn> > >&, unsigned long) @ 0xf7f0398 in /usr/bin/clickhouse
52ms [clickhouse1] 4. DB::ValuesBlockInputFormat::generate() @ 0xf7ef73c in /usr/bin/clickhouse
52ms [clickhouse1] 5. DB::ISource::tryGenerate() @ 0xf6df1b5 in /usr/bin/clickhouse
52ms [clickhouse1] 6. DB::ISource::work() @ 0xf6deeca in /usr/bin/clickhouse
53ms [clickhouse1] 7. DB::InputStreamFromInputFormat::readImpl() @ 0xce6517f in /usr/bin/clickhouse
53ms [clickhouse1] 8. DB::IBlockInputStream::read() @ 0xe710385 in /usr/bin/clickhouse
53ms [clickhouse1] 9. DB::AsynchronousBlockInputStream::calculate() @ 0xe70c701 in /usr/bin/clickhouse
53ms [clickhouse1] 10. ? @ 0xe70cf77 in /usr/bin/clickhouse
53ms [clickhouse1] 11. ThreadPoolImpl<ThreadFromGlobalPool>::worker(std::__1::__list_iterator<ThreadFromGlobalPool, void*>) @ 0x8528a48 in /usr/bin/clickhouse
53ms [clickhouse1] 12. ThreadFromGlobalPool::ThreadFromGlobalPool<void ThreadPoolImpl<ThreadFromGlobalPool>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()>(void&&, void ThreadPoolImpl<ThreadFromGlobalPool>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()&&...)::'lambda'()::operator()() @ 0x852a9ff in /usr/bin/clickhouse
53ms [clickhouse1] 13. ThreadPoolImpl<std::__1::thread>::worker(std::__1::__list_iterator<std::__1::thread, void*>) @ 0x852601f in /usr/bin/clickhouse
53ms [clickhouse1] 14. ? @ 0x8529ab3 in /usr/bin/clickhouse
53ms [clickhouse1] 15. start_thread @ 0x9609 in /usr/lib/x86_64-linux-gnu/libpthread-2.31.so
53ms [clickhouse1] 16. clone @ 0x122293 in /usr/lib/x86_64-linux-gnu/libc-2.31.so
53ms [clickhouse1] (version 21.3.1.5944 (official build))
57ms [clickhouse1] bash# echo $?
57ms [clickhouse1] 53
58ms [clickhouse1] bash#
```
**Expected behavior**
It should work. | https://github.com/ClickHouse/ClickHouse/issues/21031 | https://github.com/ClickHouse/ClickHouse/pull/20541 | 427e5f295cf0f88fc1ea0de2722f016d0998cfc7 | 7bbc4e013af6e008c53630fdeca7b6d61b4f9c8f | "2021-02-21T12:45:13Z" | c++ | "2021-02-24T09:00:48Z" |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.