v.24.9Experimental Feature
Refreshable Materialized View Enhancements in ClickHouse
Refreshable materialized view improvements: append mode (... REFRESH EVERY 1 MINUTE APPEND ...) to add rows to existing table instead of overwriting the whole table, retries (disabled by default, configured in SETTINGS section of the query),SYSTEM WAIT VIEW <name>query that waits for the currently running refresh, some fixes. #58934 (Michael Kolupaev).
Why it matters
This feature enhances refreshable materialized views by allowing incremental updates via append mode instead of overwriting the entire table, improving efficiency and reducing resource usage. It also introduces configurable retries for refresh operations and aSYSTEM WAIT VIEW <name> command to wait for ongoing refreshes, providing better control and reliability in data refresh workflows.How to use it
To use append mode, define the refreshable materialized view with the clauseREFRESH EVERY 1 MINUTE APPEND. Configure retries by adding retry settings in the SETTINGS section of the query (these are disabled by default). Use SYSTEM WAIT VIEW <name> to wait for the current refresh operation of a materialized view to complete before proceeding.