2019-12-02 23:25:08 +00:00
|
|
|
#!/usr/bin/env bash
|
|
|
|
|
|
|
|
CURDIR=$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)
|
2020-12-28 11:46:53 +00:00
|
|
|
# shellcheck source=../shell_config.sh
|
2020-08-01 00:51:12 +00:00
|
|
|
. "$CURDIR"/../shell_config.sh
|
2019-12-02 23:25:08 +00:00
|
|
|
|
|
|
|
# that test is failing on versions <= 19.11.12
|
|
|
|
|
2024-07-29 20:06:55 +00:00
|
|
|
${CLICKHOUSE_CLIENT} --query="
|
2019-12-02 23:25:08 +00:00
|
|
|
DROP TABLE IF EXISTS lc_empty_part_bug;
|
2021-03-13 07:31:19 +00:00
|
|
|
create table lc_empty_part_bug (id UInt64, s String) Engine=MergeTree ORDER BY id SETTINGS number_of_free_entries_in_pool_to_execute_mutation=0;
|
2019-12-02 23:25:08 +00:00
|
|
|
insert into lc_empty_part_bug select number as id, toString(rand()) from numbers(100);
|
|
|
|
alter table lc_empty_part_bug delete where id < 100;
|
2020-09-03 23:28:44 +00:00
|
|
|
" --mutations_sync=1
|
2019-12-02 23:25:08 +00:00
|
|
|
|
2020-09-03 23:28:44 +00:00
|
|
|
echo 'Waited for mutation to finish'
|
2019-12-02 23:25:08 +00:00
|
|
|
|
2024-07-29 20:06:55 +00:00
|
|
|
${CLICKHOUSE_CLIENT} --query="
|
2019-12-02 23:25:08 +00:00
|
|
|
alter table lc_empty_part_bug modify column s LowCardinality(String);
|
|
|
|
SELECT 'still alive';
|
|
|
|
insert into lc_empty_part_bug select number+100 as id, toString(rand()) from numbers(100);
|
|
|
|
SELECT count() FROM lc_empty_part_bug WHERE not ignore(*);
|
|
|
|
DROP TABLE lc_empty_part_bug;
|
2020-09-03 23:28:44 +00:00
|
|
|
" --mutations_sync=1
|