Как переименовать математический вид в ClickHous - PullRequest
0 голосов
/ 13 марта 2020

Как переименовать математический вид в ClickHouse?!

:) ALTER MATERIALIZED VIEW db.table_1 RENAME TO db.table_2;
Syntax error: failed at position 7


:) RENAME MATERIALIZED VIEW db.table_1 TO db.table_2;
Syntax error: failed at position 8

:) RENAME TABLE db.table_1 TO db.table_2;

RENAME TABLE table_1 TO table_2
Received exception from server (version 19.4.4):
Code: 48. DB::Exception: Received from 127.0.0.1:9000. DB::Exception: Method rename is not supported by storage MaterializedView

Помогите пожалуйста!

Ответы [ 2 ]

0 голосов
/ 13 марта 2020

Как преобразовать не реплицированный MV в реплицированный https://gist.github.com/den-crane/80cb95e74f046be2d8ffae58d9b04e8f

Как изменить MV https://gist.github.com/den-crane/431010ca08b9e51b960e55344b1dbbe3

MV_poplulating_with_freeze https://gist.github.com/den-crane/64c05be67ef8a926242011188ce96f44

Несколько_MV_one_internal_store https://gist.github.com/den-crane/005633470c70877dd28c00211cd9fcfb

Заполнить AggregatingMergeTree через нулевую таблицу https://gist.github.com/den-crane/f7382cd4f1f859ff6ac46afe7dc9925a

alter_MV_with_SummingMergeTree https://gist.github.com/den-crane/3a8d57253711e277b2a60a75b5dfeef6

Переименовать MV в CH до 19.8.3.8 https://gist.github.com/den-crane/d9a0bceb58a7d5314ea66e8edbebc9f7

0 голосов
/ 13 марта 2020

Поддержка переименования MaterializedView была добавлена ​​в следующей версии.
Версия ClickHouse 19.8.3.8, 2019-06-11

Запрос на извлечение: https://github.com/ClickHouse/ClickHouse/pull/5209

...