You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/guides/developer/on-fly-mutations.md
+2-2Lines changed: 2 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -1,12 +1,12 @@
1
1
---
2
-
slug: /guides/developer/lightweight-update
2
+
slug: /guides/developer/on-the-fly-mutations
3
3
sidebar_label: 'On-the-fly mutation'
4
4
title: 'On-the-fly Mutations'
5
5
keywords: ['On-the-fly mutation']
6
6
description: 'Provides a description of on-the-fly mutations'
7
7
---
8
8
9
-
## On-the-fly mutations {#lightweight-update}
9
+
## On-the-fly mutations {#on-the-fly-mutations}
10
10
11
11
When on-the-fly mutations are enabled, updated rows are marked as updated immediately and subsequent `SELECT` queries will automatically return with the changed values. When on-the-fly mutations are not enabled, you may have to wait for your mutations to be applied via a background process to see the changed values.
Copy file name to clipboardExpand all lines: docs/integrations/data-ingestion/etl-tools/dbt/index.md
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -815,7 +815,7 @@ In this run, only the new rows are added straight to `imdb_dbt.actor_summary` ta
815
815
816
816
Historically ClickHouse has had only limited support for updates and deletes, in the form of asynchronous [Mutations](/sql-reference/statements/alter/index.md). These can be extremely IO-intensive and should generally be avoided.
817
817
818
-
ClickHouse 22.8 introduced [lightweight deletes](/sql-reference/statements/delete.md) and ClickHouse 25.7 introduced [lightweight updates](/guides/developer/lightweight-update). With the introduction of these features, modifications from single update queries, even when being materialized asynchronously, will occur instantly from the user's perspective.
818
+
ClickHouse 22.8 introduced [lightweight deletes](/sql-reference/statements/delete.md) and ClickHouse 25.7 introduced [lightweight updates](/sql-reference/statements/update). With the introduction of these features, modifications from single update queries, even when being materialized asynchronously, will occur instantly from the user's perspective.
819
819
820
820
This mode can be configured for a model via the `incremental_strategy` parameter i.e.
|[Overview](/updating-data/overview)| Provides an overview of the differences in updating data between ClickHouse and OLTP databases, as well as the various methods available to do so in ClickHouse. |
13
13
|[Update mutations](/managing-data/update_mutations)| Learn how to update using Update Mutations. |
14
-
|[Lightweight updates](/guides/developer/lightweight-update)| Learn how to update using Lightweight Updates. |
14
+
|[Lightweight updates](/docs/sql-reference/statements/update)| Learn how to update using Lightweight Updates. |
15
15
|[ReplacingMergeTree](/guides/replacing-merge-tree)| Learn how to update using the ReplacingMergeTree. |
|[Update mutation](/sql-reference/statements/alter/update)|`ALTER TABLE [table] UPDATE`| Use when data must be updated to disk immediately (e.g. for compliance). Negatively affects `SELECT` performance. |
24
24
|[Lightweight updates](/sql-reference/statements/update)|`UPDATE [table] SET ... WHERE`| Use for updating small amounts of data (up to ~10% of table). Creates patch parts for immediate visibility without rewriting entire columns. Adds overhead to `SELECT` queries but has predictable latency. Currently experimental. |
25
-
|[On-the-fly updates](/guides/developer/lightweight-update)|`ALTER TABLE [table] UPDATE`| Enable using `SET apply_mutations_on_fly = 1;`. Use when updating small amounts of data. Rows are immediately returned with updated data in all subsequent `SELECT` queries but are initially only internally marked as updated on disk. |
25
+
|[On-the-fly updates](/guides/developer/on-the-fly-mutations)|`ALTER TABLE [table] UPDATE`| Enable using `SET apply_mutations_on_fly = 1;`. Use when updating small amounts of data. Rows are immediately returned with updated data in all subsequent `SELECT` queries but are initially only internally marked as updated on disk. |
26
26
|[ReplacingMergeTree](/engines/table-engines/mergetree-family/replacingmergetree)|`ENGINE = ReplacingMergeTree`| Use when updating large amounts of data. This table engine is optimized for data deduplication on merges. |
27
27
|[CollapsingMergeTree](/engines/table-engines/mergetree-family/collapsingmergetree)|`ENGINE = CollapsingMergeTree(Sign)`| Use when updating individual rows frequently, or for scenarios where you need to maintain the latest state of objects that change over time. For example, tracking user activity or article stats. |
28
28
Here is a summary of the different ways to update data in ClickHouse:
@@ -84,9 +84,9 @@ WHERE Id = 404346
84
84
1 row inset. Elapsed: 0.149 sec. Processed 59.55 million rows, 259.91 MB (399.99 million rows/s., 1.75 GB/s.)
85
85
```
86
86
87
-
Note that for on-the-fly updates, a mutation is still used to update the data; it is just not materialized immediately and applied during `SELECT` queries. It will still be applied in the background as an asynchronous process and incurs the same heavy overhead as a mutation and thus is an I/O intense operation that should be used sparingly. The expressions that can be used with this operation are also limited (see here for [details](/guides/developer/lightweight-update#support-for-subqueries-and-non-deterministic-functions)).
87
+
Note that for on-the-fly updates, a mutation is still used to update the data; it is just not materialized immediately and applied during `SELECT` queries. It will still be applied in the background as an asynchronous process and incurs the same heavy overhead as a mutation and thus is an I/O intense operation that should be used sparingly. The expressions that can be used with this operation are also limited (see here for [details](/guides/developer/on-the-fly-mutations#support-for-subqueries-and-non-deterministic-functions)).
88
88
89
-
Read more about [on-the-fly updates](/guides/developer/lightweight-update).
89
+
Read more about [on-the-fly updates](/guides/developer/on-the-fly-mutations).
0 commit comments