dbeaver icon indicating copy to clipboard operation
dbeaver copied to clipboard

The temporary parameter settings for clickhouse are invalid

Open dibrother opened this issue 10 months ago • 1 comments

Description

I want to not immediately apply new TTL rules to existing data,so before executing the TTL alter statement, I executed "set materialize_ttl-afteer_modify=0;",but it doesn't take effect, When execute "Alter Table test.tb_testa MODIFY TTL date+INTERVAL 70 DAY DELETE; "It will take effect immediately.

However, when I use clickhouse-client to execute “set materialize_ttl-afteer_modify=0;”, The change will take effect when the Alter is executed later.

Is there an issue with the session settings and there is no keep?

DBeaver Version

23.3.4.202402041841

Operating System

macOS Sonoma 14.1.1

Database and driver

Official ClickHouse driver (server version 21.3+)

Steps to reproduce

  1. Prepare a table with a large amount of data (such as 20 million rows)

  2. Connect Dbeaver to open a window and execute "set Materialize_ttl afterer_modify=0;"

  3. Continue to execute "Alter Table test.tb-test MODIFY TTL date+INTERVAL 70 DAY Delete;" (it can be found that historical data has been deleted after execution)

  4. Use clickhouse client to connect to clickhouse

  5. Execute "set materialize_ttl afterer_modify=0;"

  6. Continue to execute "Alter Table test.tb-test MODIFY TTL date+INTERVAL 70 DAY Delete;" (it can be found that the historical data has not been deleted after execution, and the above parameters)

Additional context

No response

dibrother avatar Apr 10 '24 09:04 dibrother

Hi @dibrother

I can't get past the SQL Error [62] [07000]: Code: 62. DB::Exception: Syntax error: failed at position 21 ('afterer_modify'): afterer_modify=0. Expected one of: token, Dot, Equals. (SYNTAX_ERROR) (version 22.1.3.7 (official build)) after I try to execute

set Materialize_ttl afterer_modify=0;

Need some more time to investigate it.

hrimthrusa avatar May 09 '24 11:05 hrimthrusa

Does this query successfully executed for you in DBeaver? set Materialize_ttl afterer_modify=0;

Also could you tell me your driver and server version? You can get this information by clicking Test connection... button in the Connection configuration dialog. image

E1izabeth avatar Jul 04 '24 13:07 E1izabeth

It's been a while since no update here. If the issue is still actual please let me know and provide additional information.

E1izabeth avatar Aug 01 '24 09:08 E1izabeth