diff --git a/src/current/v23.2/row-level-ttl.md b/src/current/v23.2/row-level-ttl.md
index 9a68549da52..eb024ccc7ac 100644
--- a/src/current/v23.2/row-level-ttl.md
+++ b/src/current/v23.2/row-level-ttl.md
@@ -147,10 +147,10 @@ The settings that control the behavior of Row-Level TTL are provided using [stor
| `ttl_expiration_expression` | **Recommended**. SQL expression that defines the TTL expiration. Must evaluate to a [`TIMESTAMPTZ`]({% link {{ page.version.version }}/timestamp.md %}). This and/or [`ttl_expire_after`](#param-ttl-expire-after) are required to enable TTL. This parameter is useful when you want to set the TTL for individual rows in the table. For an example, see [Create a table with a `ttl_expiration_expression`](#create-a-table-with-a-ttl_expiration_expression). | N/A |
| `ttl_expire_after` | The [interval]({% link {{ page.version.version }}/interval.md %}) when a TTL will expire. This and/or [`ttl_expiration_expression`](#param-ttl-expiration-expression) are required to enable TTL. Minimum value: `'1 microsecond'`. | N/A |
| `ttl` | Signifies if a TTL is active. Automatically set. | N/A |
-| `ttl_select_batch_size` | How many rows to [select]({% link {{ page.version.version }}/select-clause.md %}) at one time during the row expiration check. Default: 500. Minimum: 1. | `sql.ttl.default_select_batch_size` |
-| `ttl_delete_batch_size` | How many rows to [delete]({% link {{ page.version.version }}/delete.md %}) at a time. Default: 100. Minimum: 1. | `sql.ttl.default_delete_batch_size` |
-| `ttl_select_rate_limit` | Maximum number of rows to be selected per second (rate limit). Default: 0 (no limit).
Note: The rate limit is applied per leaseholder per table. In practice, it will vary based on the number of [ranges]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-range) and [leaseholders]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-leaseholder).
For example, if this variable is set to 500, and a table `public.foo` has its ranges spread across 3 leaseholders, then the cluster-wide rate limit for `public.foo` is 500 x 3 = 1500.
To determine the number of leaseholders for some table `public.bar` on CockroachDB v23.1+, issue the following query against the output of [`SHOW RANGES ... WITH DETAILS`]({% link {{ page.version.version }}/show-ranges.md %}#show-ranges-for-a-table-with-details):
`SELECT count(DISTINCT lease_holder) FROM [SHOW RANGES FROM TABLE public.bar WITH DETAILS];` | `sql.ttl.default_select_rate_limit` |
-| `ttl_delete_rate_limit` | Maximum number of rows to be deleted per second (rate limit). Default: 100 (Set to 0 for no limit).
Note: The rate limit is applied per leaseholder per table. In practice, it will vary based on the number of [ranges]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-range) and [leaseholders]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-leaseholder).
For example, if this variable is set to 500, and a table `public.foo` has its ranges spread across 3 leaseholders, then the cluster-wide rate limit for `public.foo` is 500 x 3 = 1500.
To determine the number of leaseholders for some table `public.bar` on CockroachDB v23.1+, issue the following query against the output of [`SHOW RANGES ... WITH DETAILS`]({% link {{ page.version.version }}/show-ranges.md %}#show-ranges-for-a-table-with-details):
`SELECT count(DISTINCT lease_holder) FROM [SHOW RANGES FROM TABLE public.bar WITH DETAILS];` | `sql.ttl.default_delete_rate_limit` |
+| `ttl_select_batch_size` | How many rows to [select]({% link {{ page.version.version }}/select-clause.md %}) at one time during the row expiration check. Defaults to the value of the associated cluster setting if unset. | `sql.ttl.default_select_batch_size`
Default: 500. Minimum: 1. |
+| `ttl_delete_batch_size` | How many rows to [delete]({% link {{ page.version.version }}/delete.md %}) at a time. Defaults to the value of the associated cluster setting if unset.| `sql.ttl.default_delete_batch_size`
Default: 100. Minimum: 1. |
+| `ttl_select_rate_limit` | Maximum number of rows to be selected per second (rate limit). Defaults to the value of the associated cluster setting if unset.
Note: The rate limit is applied per leaseholder per table. In practice, it will vary based on the number of [ranges]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-range) and [leaseholders]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-leaseholder).
For example, if this variable is set to 500, and a table `public.foo` has its ranges spread across 3 leaseholders, then the cluster-wide rate limit for `public.foo` is 500 x 3 = 1500.
To determine the number of leaseholders for some table `public.bar` on CockroachDB v23.1+, issue the following query against the output of [`SHOW RANGES ... WITH DETAILS`]({% link {{ page.version.version }}/show-ranges.md %}#show-ranges-for-a-table-with-details):
`SELECT count(DISTINCT lease_holder) FROM [SHOW RANGES FROM TABLE public.bar WITH DETAILS];` | `sql.ttl.default_select_rate_limit`
Default: 0. Minimum: 0 (unlimited).|
+| `ttl_delete_rate_limit` | Maximum number of rows to be deleted per second (rate limit). Defaults to the value of the associated cluster setting if unset.
Note: The rate limit is applied per leaseholder per table. In practice, it will vary based on the number of [ranges]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-range) and [leaseholders]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-leaseholder).
For example, if this variable is set to 500, and a table `public.foo` has its ranges spread across 3 leaseholders, then the cluster-wide rate limit for `public.foo` is 500 x 3 = 1500.
To determine the number of leaseholders for some table `public.bar` on CockroachDB v23.1+, issue the following query against the output of [`SHOW RANGES ... WITH DETAILS`]({% link {{ page.version.version }}/show-ranges.md %}#show-ranges-for-a-table-with-details):
`SELECT count(DISTINCT lease_holder) FROM [SHOW RANGES FROM TABLE public.bar WITH DETAILS];` | `sql.ttl.default_delete_rate_limit`
Default: 100. Minimum: 0 (unlimited).|
| `ttl_row_stats_poll_interval` | If set, counts rows and expired rows on the table to report as Prometheus metrics while the TTL job is running. Unset by default, meaning no stats are fetched and reported. | N/A |
| `ttl_pause` | If set, stops the TTL job from executing. | N/A |
| `ttl_job_cron` | Frequency at which the TTL job runs, specified using [CRON syntax](https://cron.help). New in v23.2: Default: `'@daily'` (was `'@hourly'`). | N/A |
@@ -516,8 +516,9 @@ WITH x AS (SHOW CLUSTER SETTINGS) SELECT * FROM x WHERE variable LIKE 'sql.ttl.%
sql.ttl.default_delete_batch_size | 100 | i | default amount of rows to delete in a single query during a TTL job
sql.ttl.default_delete_rate_limit | 100 | i | default delete rate limit for all TTL jobs. Use 0 to signify no rate limit.
sql.ttl.default_select_batch_size | 500 | i | default amount of rows to select in a single query during a TTL job
+ sql.ttl.default_select_rate_limit | 0 | i | default select rate limit for all TTL jobs. Use 0 to signify no rate limit.
sql.ttl.job.enabled | false | b | whether the TTL job is enabled
-(5 rows)
+(6 rows)
~~~
## Common errors
diff --git a/src/current/v24.1/row-level-ttl.md b/src/current/v24.1/row-level-ttl.md
index fa665cb9e14..8d33724c462 100644
--- a/src/current/v24.1/row-level-ttl.md
+++ b/src/current/v24.1/row-level-ttl.md
@@ -146,10 +146,10 @@ The settings that control the behavior of Row-Level TTL are provided using [stor
| `ttl_expiration_expression` | **Recommended**. SQL expression that defines the TTL expiration. Must evaluate to a [`TIMESTAMPTZ`]({% link {{ page.version.version }}/timestamp.md %}). This and/or [`ttl_expire_after`](#param-ttl-expire-after) are required to enable TTL. This parameter is useful when you want to set the TTL for individual rows in the table. For an example, see [Create a table with a `ttl_expiration_expression`](#create-a-table-with-a-ttl_expiration_expression). | N/A |
| `ttl_expire_after` | The [interval]({% link {{ page.version.version }}/interval.md %}) when a TTL will expire. This and/or [`ttl_expiration_expression`](#param-ttl-expiration-expression) are required to enable TTL. Minimum value: `'1 microsecond'`. | N/A |
| `ttl` | Signifies if a TTL is active. Automatically set. | N/A |
-| `ttl_select_batch_size` | How many rows to [select]({% link {{ page.version.version }}/select-clause.md %}) at one time during the row expiration check. Default: 500. Minimum: 1. | `sql.ttl.default_select_batch_size` |
-| `ttl_delete_batch_size` | How many rows to [delete]({% link {{ page.version.version }}/delete.md %}) at a time. Default: 100. Minimum: 1. | `sql.ttl.default_delete_batch_size` |
-| `ttl_select_rate_limit` | Maximum number of rows to be selected per second (rate limit). Default: 0 (no limit).
Note: The rate limit is applied per leaseholder per table. In practice, it will vary based on the number of [ranges]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-range) and [leaseholders]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-leaseholder).
For example, if this variable is set to 500, and a table `public.foo` has its ranges spread across 3 leaseholders, then the cluster-wide rate limit for `public.foo` is 500 x 3 = 1500.
To determine the number of leaseholders for some table `public.bar` on CockroachDB v23.1+, issue the following query against the output of [`SHOW RANGES ... WITH DETAILS`]({% link {{ page.version.version }}/show-ranges.md %}#show-ranges-for-a-table-with-details):
`SELECT count(DISTINCT lease_holder) FROM [SHOW RANGES FROM TABLE public.bar WITH DETAILS];` | `sql.ttl.default_select_rate_limit` |
-| `ttl_delete_rate_limit` | Maximum number of rows to be deleted per second (rate limit). Default: 100 (set to 0 for no limit).
Note: The rate limit is applied per leaseholder per table. In practice, it will vary based on the number of [ranges]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-range) and [leaseholders]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-leaseholder).
For example, if this variable is set to 500, and a table `public.foo` has its ranges spread across 3 leaseholders, then the cluster-wide rate limit for `public.foo` is 500 x 3 = 1500.
To determine the number of leaseholders for some table `public.bar` on CockroachDB v23.1+, issue the following query against the output of [`SHOW RANGES ... WITH DETAILS`]({% link {{ page.version.version }}/show-ranges.md %}#show-ranges-for-a-table-with-details):
`SELECT count(DISTINCT lease_holder) FROM [SHOW RANGES FROM TABLE public.bar WITH DETAILS];` | `sql.ttl.default_delete_rate_limit` |
+| `ttl_select_batch_size` | How many rows to [select]({% link {{ page.version.version }}/select-clause.md %}) at one time during the row expiration check. Defaults to the value of the associated cluster setting if unset. | `sql.ttl.default_select_batch_size`
Default: 500. Minimum: 1. |
+| `ttl_delete_batch_size` | How many rows to [delete]({% link {{ page.version.version }}/delete.md %}) at a time. Defaults to the value of the associated cluster setting if unset. | `sql.ttl.default_delete_batch_size`
Default: 100. Minimum: 1. |
+| `ttl_select_rate_limit` | Maximum number of rows to be selected per second (rate limit). Defaults to the value of the associated cluster setting if unset.
Note: The rate limit is applied per leaseholder per table. In practice, it will vary based on the number of [ranges]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-range) and [leaseholders]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-leaseholder).
For example, if this variable is set to 500, and a table `public.foo` has its ranges spread across 3 leaseholders, then the cluster-wide rate limit for `public.foo` is 500 x 3 = 1500.
To determine the number of leaseholders for some table `public.bar` on CockroachDB v23.1+, issue the following query against the output of [`SHOW RANGES ... WITH DETAILS`]({% link {{ page.version.version }}/show-ranges.md %}#show-ranges-for-a-table-with-details):
`SELECT count(DISTINCT lease_holder) FROM [SHOW RANGES FROM TABLE public.bar WITH DETAILS];` | `sql.ttl.default_select_rate_limit`
Default: 0. Minimum: 0 (unlimited). |
+| `ttl_delete_rate_limit` | Maximum number of rows to be deleted per second (rate limit). Defaults to the value of the associated cluster setting if unset.
Note: The rate limit is applied per leaseholder per table. In practice, it will vary based on the number of [ranges]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-range) and [leaseholders]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-leaseholder).
For example, if this variable is set to 500, and a table `public.foo` has its ranges spread across 3 leaseholders, then the cluster-wide rate limit for `public.foo` is 500 x 3 = 1500.
To determine the number of leaseholders for some table `public.bar` on CockroachDB v23.1+, issue the following query against the output of [`SHOW RANGES ... WITH DETAILS`]({% link {{ page.version.version }}/show-ranges.md %}#show-ranges-for-a-table-with-details):
`SELECT count(DISTINCT lease_holder) FROM [SHOW RANGES FROM TABLE public.bar WITH DETAILS];` | `sql.ttl.default_delete_rate_limit`
Default: 100. Minimum: 0 (unlimited). |
| `ttl_row_stats_poll_interval` | If set, counts rows and expired rows on the table to report as Prometheus metrics while the TTL job is running. Unset by default, meaning no stats are fetched and reported. | N/A |
| `ttl_pause` | If set, stops the TTL job from executing. | N/A |
| `ttl_job_cron` | Frequency at which the TTL job runs, specified using [CRON syntax](https://cron.help). Default: `'@daily'` (was `'@hourly'`). | N/A |
@@ -516,8 +516,9 @@ WITH x AS (SHOW CLUSTER SETTINGS) SELECT * FROM x WHERE variable LIKE 'sql.ttl.%
sql.ttl.default_delete_batch_size | 100 | i | default amount of rows to delete in a single query during a TTL job
sql.ttl.default_delete_rate_limit | 100 | i | default delete rate limit for all TTL jobs. Use 0 to signify no rate limit.
sql.ttl.default_select_batch_size | 500 | i | default amount of rows to select in a single query during a TTL job
+ sql.ttl.default_select_rate_limit | 0 | i | default select rate limit for all TTL jobs. Use 0 to signify no rate limit.
sql.ttl.job.enabled | false | b | whether the TTL job is enabled
-(5 rows)
+(6 rows)
~~~
## Common errors
diff --git a/src/current/v24.2/row-level-ttl.md b/src/current/v24.2/row-level-ttl.md
index edac9170806..aaec52dafb3 100644
--- a/src/current/v24.2/row-level-ttl.md
+++ b/src/current/v24.2/row-level-ttl.md
@@ -146,10 +146,10 @@ The settings that control the behavior of Row-Level TTL are provided using [stor
| `ttl_expiration_expression` | **Recommended**. SQL expression that defines the TTL expiration. Must evaluate to a [`TIMESTAMPTZ`]({% link {{ page.version.version }}/timestamp.md %}). This and/or [`ttl_expire_after`](#param-ttl-expire-after) are required to enable TTL. This parameter is useful when you want to set the TTL for individual rows in the table. For an example, see [Create a table with a `ttl_expiration_expression`](#create-a-table-with-a-ttl_expiration_expression). | N/A |
| `ttl_expire_after` | The [interval]({% link {{ page.version.version }}/interval.md %}) when a TTL will expire. This and/or [`ttl_expiration_expression`](#param-ttl-expiration-expression) are required to enable TTL. Minimum value: `'1 microsecond'`. | N/A |
| `ttl` | Signifies if a TTL is active. Automatically set. | N/A |
-| `ttl_select_batch_size` | How many rows to [select]({% link {{ page.version.version }}/select-clause.md %}) at one time during the row expiration check. Default: 500. Minimum: 1. | `sql.ttl.default_select_batch_size` |
-| `ttl_delete_batch_size` | How many rows to [delete]({% link {{ page.version.version }}/delete.md %}) at a time. Default: 100. Minimum: 1. | `sql.ttl.default_delete_batch_size` |
-| `ttl_select_rate_limit` | Maximum number of rows to be selected per second (rate limit). Default: 0 (no limit).
Note: The rate limit is applied per leaseholder per table. In practice, it will vary based on the number of [ranges]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-range) and [leaseholders]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-leaseholder).
For example, if this variable is set to 500, and a table `public.foo` has its ranges spread across 3 leaseholders, then the cluster-wide rate limit for `public.foo` is 500 x 3 = 1500.
To determine the number of leaseholders for some table `public.bar` on CockroachDB v23.1+, issue the following query against the output of [`SHOW RANGES ... WITH DETAILS`]({% link {{ page.version.version }}/show-ranges.md %}#show-ranges-for-a-table-with-details):
`SELECT count(DISTINCT lease_holder) FROM [SHOW RANGES FROM TABLE public.bar WITH DETAILS];` | `sql.ttl.default_select_rate_limit` |
-| `ttl_delete_rate_limit` | Maximum number of rows to be deleted per second (rate limit). Default: 100 (set to 0 for no limit).
Note: The rate limit is applied per leaseholder per table. In practice, it will vary based on the number of [ranges]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-range) and [leaseholders]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-leaseholder).
For example, if this variable is set to 500, and a table `public.foo` has its ranges spread across 3 leaseholders, then the cluster-wide rate limit for `public.foo` is 500 x 3 = 1500.
To determine the number of leaseholders for some table `public.bar` on CockroachDB v23.1+, issue the following query against the output of [`SHOW RANGES ... WITH DETAILS`]({% link {{ page.version.version }}/show-ranges.md %}#show-ranges-for-a-table-with-details):
`SELECT count(DISTINCT lease_holder) FROM [SHOW RANGES FROM TABLE public.bar WITH DETAILS];` | `sql.ttl.default_delete_rate_limit` |
+| `ttl_select_batch_size` | How many rows to [select]({% link {{ page.version.version }}/select-clause.md %}) at one time during the row expiration check. Defaults to the value of the associated cluster setting if unset. | `sql.ttl.default_select_batch_size`
Default: 500. Minimum: 1. |
+| `ttl_delete_batch_size` | How many rows to [delete]({% link {{ page.version.version }}/delete.md %}) at a time. Defaults to the value of the associated cluster setting if unset. | `sql.ttl.default_delete_batch_size`
Default: 100. Minimum: 1. |
+| `ttl_select_rate_limit` | Maximum number of rows to be selected per second (rate limit). Defaults to the value of the associated cluster setting if unset.
Note: The rate limit is applied per leaseholder per table. In practice, it will vary based on the number of [ranges]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-range) and [leaseholders]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-leaseholder).
For example, if this variable is set to 500, and a table `public.foo` has its ranges spread across 3 leaseholders, then the cluster-wide rate limit for `public.foo` is 500 x 3 = 1500.
To determine the number of leaseholders for some table `public.bar` on CockroachDB v23.1+, issue the following query against the output of [`SHOW RANGES ... WITH DETAILS`]({% link {{ page.version.version }}/show-ranges.md %}#show-ranges-for-a-table-with-details):
`SELECT count(DISTINCT lease_holder) FROM [SHOW RANGES FROM TABLE public.bar WITH DETAILS];` | `sql.ttl.default_select_rate_limit`
Default: 0. Minimum: 0 (unlimited). |
+| `ttl_delete_rate_limit` | Maximum number of rows to be deleted per second (rate limit). Defaults to the value of the associated cluster setting if unset.
Note: The rate limit is applied per leaseholder per table. In practice, it will vary based on the number of [ranges]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-range) and [leaseholders]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-leaseholder).
For example, if this variable is set to 500, and a table `public.foo` has its ranges spread across 3 leaseholders, then the cluster-wide rate limit for `public.foo` is 500 x 3 = 1500.
To determine the number of leaseholders for some table `public.bar` on CockroachDB v23.1+, issue the following query against the output of [`SHOW RANGES ... WITH DETAILS`]({% link {{ page.version.version }}/show-ranges.md %}#show-ranges-for-a-table-with-details):
`SELECT count(DISTINCT lease_holder) FROM [SHOW RANGES FROM TABLE public.bar WITH DETAILS];` | `sql.ttl.default_delete_rate_limit`
Default: 100. Minimum: 0 (unlimited). |
| `ttl_row_stats_poll_interval` | If set, counts rows and expired rows on the table to report as Prometheus metrics while the TTL job is running. Unset by default, meaning no stats are fetched and reported. | N/A |
| `ttl_pause` | If set, stops the TTL job from executing. | N/A |
| `ttl_job_cron` | Frequency at which the TTL job runs, specified using [CRON syntax](https://cron.help). Default: `'@daily'` (was `'@hourly'`). | N/A |
@@ -516,8 +516,9 @@ WITH x AS (SHOW CLUSTER SETTINGS) SELECT * FROM x WHERE variable LIKE 'sql.ttl.%
sql.ttl.default_delete_batch_size | 100 | i | default amount of rows to delete in a single query during a TTL job
sql.ttl.default_delete_rate_limit | 100 | i | default delete rate limit for all TTL jobs. Use 0 to signify no rate limit.
sql.ttl.default_select_batch_size | 500 | i | default amount of rows to select in a single query during a TTL job
+ sql.ttl.default_select_rate_limit | 0 | i | default select rate limit for all TTL jobs. Use 0 to signify no rate limit.
sql.ttl.job.enabled | false | b | whether the TTL job is enabled
-(5 rows)
+(6 rows)
~~~
## Common errors
diff --git a/src/current/v24.3/row-level-ttl.md b/src/current/v24.3/row-level-ttl.md
index edac9170806..aaec52dafb3 100644
--- a/src/current/v24.3/row-level-ttl.md
+++ b/src/current/v24.3/row-level-ttl.md
@@ -146,10 +146,10 @@ The settings that control the behavior of Row-Level TTL are provided using [stor
| `ttl_expiration_expression` | **Recommended**. SQL expression that defines the TTL expiration. Must evaluate to a [`TIMESTAMPTZ`]({% link {{ page.version.version }}/timestamp.md %}). This and/or [`ttl_expire_after`](#param-ttl-expire-after) are required to enable TTL. This parameter is useful when you want to set the TTL for individual rows in the table. For an example, see [Create a table with a `ttl_expiration_expression`](#create-a-table-with-a-ttl_expiration_expression). | N/A |
| `ttl_expire_after` | The [interval]({% link {{ page.version.version }}/interval.md %}) when a TTL will expire. This and/or [`ttl_expiration_expression`](#param-ttl-expiration-expression) are required to enable TTL. Minimum value: `'1 microsecond'`. | N/A |
| `ttl` | Signifies if a TTL is active. Automatically set. | N/A |
-| `ttl_select_batch_size` | How many rows to [select]({% link {{ page.version.version }}/select-clause.md %}) at one time during the row expiration check. Default: 500. Minimum: 1. | `sql.ttl.default_select_batch_size` |
-| `ttl_delete_batch_size` | How many rows to [delete]({% link {{ page.version.version }}/delete.md %}) at a time. Default: 100. Minimum: 1. | `sql.ttl.default_delete_batch_size` |
-| `ttl_select_rate_limit` | Maximum number of rows to be selected per second (rate limit). Default: 0 (no limit).
Note: The rate limit is applied per leaseholder per table. In practice, it will vary based on the number of [ranges]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-range) and [leaseholders]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-leaseholder).
For example, if this variable is set to 500, and a table `public.foo` has its ranges spread across 3 leaseholders, then the cluster-wide rate limit for `public.foo` is 500 x 3 = 1500.
To determine the number of leaseholders for some table `public.bar` on CockroachDB v23.1+, issue the following query against the output of [`SHOW RANGES ... WITH DETAILS`]({% link {{ page.version.version }}/show-ranges.md %}#show-ranges-for-a-table-with-details):
`SELECT count(DISTINCT lease_holder) FROM [SHOW RANGES FROM TABLE public.bar WITH DETAILS];` | `sql.ttl.default_select_rate_limit` |
-| `ttl_delete_rate_limit` | Maximum number of rows to be deleted per second (rate limit). Default: 100 (set to 0 for no limit).
Note: The rate limit is applied per leaseholder per table. In practice, it will vary based on the number of [ranges]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-range) and [leaseholders]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-leaseholder).
For example, if this variable is set to 500, and a table `public.foo` has its ranges spread across 3 leaseholders, then the cluster-wide rate limit for `public.foo` is 500 x 3 = 1500.
To determine the number of leaseholders for some table `public.bar` on CockroachDB v23.1+, issue the following query against the output of [`SHOW RANGES ... WITH DETAILS`]({% link {{ page.version.version }}/show-ranges.md %}#show-ranges-for-a-table-with-details):
`SELECT count(DISTINCT lease_holder) FROM [SHOW RANGES FROM TABLE public.bar WITH DETAILS];` | `sql.ttl.default_delete_rate_limit` |
+| `ttl_select_batch_size` | How many rows to [select]({% link {{ page.version.version }}/select-clause.md %}) at one time during the row expiration check. Defaults to the value of the associated cluster setting if unset. | `sql.ttl.default_select_batch_size`
Default: 500. Minimum: 1. |
+| `ttl_delete_batch_size` | How many rows to [delete]({% link {{ page.version.version }}/delete.md %}) at a time. Defaults to the value of the associated cluster setting if unset. | `sql.ttl.default_delete_batch_size`
Default: 100. Minimum: 1. |
+| `ttl_select_rate_limit` | Maximum number of rows to be selected per second (rate limit). Defaults to the value of the associated cluster setting if unset.
Note: The rate limit is applied per leaseholder per table. In practice, it will vary based on the number of [ranges]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-range) and [leaseholders]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-leaseholder).
For example, if this variable is set to 500, and a table `public.foo` has its ranges spread across 3 leaseholders, then the cluster-wide rate limit for `public.foo` is 500 x 3 = 1500.
To determine the number of leaseholders for some table `public.bar` on CockroachDB v23.1+, issue the following query against the output of [`SHOW RANGES ... WITH DETAILS`]({% link {{ page.version.version }}/show-ranges.md %}#show-ranges-for-a-table-with-details):
`SELECT count(DISTINCT lease_holder) FROM [SHOW RANGES FROM TABLE public.bar WITH DETAILS];` | `sql.ttl.default_select_rate_limit`
Default: 0. Minimum: 0 (unlimited). |
+| `ttl_delete_rate_limit` | Maximum number of rows to be deleted per second (rate limit). Defaults to the value of the associated cluster setting if unset.
Note: The rate limit is applied per leaseholder per table. In practice, it will vary based on the number of [ranges]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-range) and [leaseholders]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-leaseholder).
For example, if this variable is set to 500, and a table `public.foo` has its ranges spread across 3 leaseholders, then the cluster-wide rate limit for `public.foo` is 500 x 3 = 1500.
To determine the number of leaseholders for some table `public.bar` on CockroachDB v23.1+, issue the following query against the output of [`SHOW RANGES ... WITH DETAILS`]({% link {{ page.version.version }}/show-ranges.md %}#show-ranges-for-a-table-with-details):
`SELECT count(DISTINCT lease_holder) FROM [SHOW RANGES FROM TABLE public.bar WITH DETAILS];` | `sql.ttl.default_delete_rate_limit`
Default: 100. Minimum: 0 (unlimited). |
| `ttl_row_stats_poll_interval` | If set, counts rows and expired rows on the table to report as Prometheus metrics while the TTL job is running. Unset by default, meaning no stats are fetched and reported. | N/A |
| `ttl_pause` | If set, stops the TTL job from executing. | N/A |
| `ttl_job_cron` | Frequency at which the TTL job runs, specified using [CRON syntax](https://cron.help). Default: `'@daily'` (was `'@hourly'`). | N/A |
@@ -516,8 +516,9 @@ WITH x AS (SHOW CLUSTER SETTINGS) SELECT * FROM x WHERE variable LIKE 'sql.ttl.%
sql.ttl.default_delete_batch_size | 100 | i | default amount of rows to delete in a single query during a TTL job
sql.ttl.default_delete_rate_limit | 100 | i | default delete rate limit for all TTL jobs. Use 0 to signify no rate limit.
sql.ttl.default_select_batch_size | 500 | i | default amount of rows to select in a single query during a TTL job
+ sql.ttl.default_select_rate_limit | 0 | i | default select rate limit for all TTL jobs. Use 0 to signify no rate limit.
sql.ttl.job.enabled | false | b | whether the TTL job is enabled
-(5 rows)
+(6 rows)
~~~
## Common errors
diff --git a/src/current/v25.1/row-level-ttl.md b/src/current/v25.1/row-level-ttl.md
index edac9170806..aaec52dafb3 100644
--- a/src/current/v25.1/row-level-ttl.md
+++ b/src/current/v25.1/row-level-ttl.md
@@ -146,10 +146,10 @@ The settings that control the behavior of Row-Level TTL are provided using [stor
| `ttl_expiration_expression` | **Recommended**. SQL expression that defines the TTL expiration. Must evaluate to a [`TIMESTAMPTZ`]({% link {{ page.version.version }}/timestamp.md %}). This and/or [`ttl_expire_after`](#param-ttl-expire-after) are required to enable TTL. This parameter is useful when you want to set the TTL for individual rows in the table. For an example, see [Create a table with a `ttl_expiration_expression`](#create-a-table-with-a-ttl_expiration_expression). | N/A |
| `ttl_expire_after` | The [interval]({% link {{ page.version.version }}/interval.md %}) when a TTL will expire. This and/or [`ttl_expiration_expression`](#param-ttl-expiration-expression) are required to enable TTL. Minimum value: `'1 microsecond'`. | N/A |
| `ttl` | Signifies if a TTL is active. Automatically set. | N/A |
-| `ttl_select_batch_size` | How many rows to [select]({% link {{ page.version.version }}/select-clause.md %}) at one time during the row expiration check. Default: 500. Minimum: 1. | `sql.ttl.default_select_batch_size` |
-| `ttl_delete_batch_size` | How many rows to [delete]({% link {{ page.version.version }}/delete.md %}) at a time. Default: 100. Minimum: 1. | `sql.ttl.default_delete_batch_size` |
-| `ttl_select_rate_limit` | Maximum number of rows to be selected per second (rate limit). Default: 0 (no limit).
Note: The rate limit is applied per leaseholder per table. In practice, it will vary based on the number of [ranges]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-range) and [leaseholders]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-leaseholder).
For example, if this variable is set to 500, and a table `public.foo` has its ranges spread across 3 leaseholders, then the cluster-wide rate limit for `public.foo` is 500 x 3 = 1500.
To determine the number of leaseholders for some table `public.bar` on CockroachDB v23.1+, issue the following query against the output of [`SHOW RANGES ... WITH DETAILS`]({% link {{ page.version.version }}/show-ranges.md %}#show-ranges-for-a-table-with-details):
`SELECT count(DISTINCT lease_holder) FROM [SHOW RANGES FROM TABLE public.bar WITH DETAILS];` | `sql.ttl.default_select_rate_limit` |
-| `ttl_delete_rate_limit` | Maximum number of rows to be deleted per second (rate limit). Default: 100 (set to 0 for no limit).
Note: The rate limit is applied per leaseholder per table. In practice, it will vary based on the number of [ranges]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-range) and [leaseholders]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-leaseholder).
For example, if this variable is set to 500, and a table `public.foo` has its ranges spread across 3 leaseholders, then the cluster-wide rate limit for `public.foo` is 500 x 3 = 1500.
To determine the number of leaseholders for some table `public.bar` on CockroachDB v23.1+, issue the following query against the output of [`SHOW RANGES ... WITH DETAILS`]({% link {{ page.version.version }}/show-ranges.md %}#show-ranges-for-a-table-with-details):
`SELECT count(DISTINCT lease_holder) FROM [SHOW RANGES FROM TABLE public.bar WITH DETAILS];` | `sql.ttl.default_delete_rate_limit` |
+| `ttl_select_batch_size` | How many rows to [select]({% link {{ page.version.version }}/select-clause.md %}) at one time during the row expiration check. Defaults to the value of the associated cluster setting if unset. | `sql.ttl.default_select_batch_size`
Default: 500. Minimum: 1. |
+| `ttl_delete_batch_size` | How many rows to [delete]({% link {{ page.version.version }}/delete.md %}) at a time. Defaults to the value of the associated cluster setting if unset. | `sql.ttl.default_delete_batch_size`
Default: 100. Minimum: 1. |
+| `ttl_select_rate_limit` | Maximum number of rows to be selected per second (rate limit). Defaults to the value of the associated cluster setting if unset.
Note: The rate limit is applied per leaseholder per table. In practice, it will vary based on the number of [ranges]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-range) and [leaseholders]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-leaseholder).
For example, if this variable is set to 500, and a table `public.foo` has its ranges spread across 3 leaseholders, then the cluster-wide rate limit for `public.foo` is 500 x 3 = 1500.
To determine the number of leaseholders for some table `public.bar` on CockroachDB v23.1+, issue the following query against the output of [`SHOW RANGES ... WITH DETAILS`]({% link {{ page.version.version }}/show-ranges.md %}#show-ranges-for-a-table-with-details):
`SELECT count(DISTINCT lease_holder) FROM [SHOW RANGES FROM TABLE public.bar WITH DETAILS];` | `sql.ttl.default_select_rate_limit`
Default: 0. Minimum: 0 (unlimited). |
+| `ttl_delete_rate_limit` | Maximum number of rows to be deleted per second (rate limit). Defaults to the value of the associated cluster setting if unset.
Note: The rate limit is applied per leaseholder per table. In practice, it will vary based on the number of [ranges]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-range) and [leaseholders]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-leaseholder).
For example, if this variable is set to 500, and a table `public.foo` has its ranges spread across 3 leaseholders, then the cluster-wide rate limit for `public.foo` is 500 x 3 = 1500.
To determine the number of leaseholders for some table `public.bar` on CockroachDB v23.1+, issue the following query against the output of [`SHOW RANGES ... WITH DETAILS`]({% link {{ page.version.version }}/show-ranges.md %}#show-ranges-for-a-table-with-details):
`SELECT count(DISTINCT lease_holder) FROM [SHOW RANGES FROM TABLE public.bar WITH DETAILS];` | `sql.ttl.default_delete_rate_limit`
Default: 100. Minimum: 0 (unlimited). |
| `ttl_row_stats_poll_interval` | If set, counts rows and expired rows on the table to report as Prometheus metrics while the TTL job is running. Unset by default, meaning no stats are fetched and reported. | N/A |
| `ttl_pause` | If set, stops the TTL job from executing. | N/A |
| `ttl_job_cron` | Frequency at which the TTL job runs, specified using [CRON syntax](https://cron.help). Default: `'@daily'` (was `'@hourly'`). | N/A |
@@ -516,8 +516,9 @@ WITH x AS (SHOW CLUSTER SETTINGS) SELECT * FROM x WHERE variable LIKE 'sql.ttl.%
sql.ttl.default_delete_batch_size | 100 | i | default amount of rows to delete in a single query during a TTL job
sql.ttl.default_delete_rate_limit | 100 | i | default delete rate limit for all TTL jobs. Use 0 to signify no rate limit.
sql.ttl.default_select_batch_size | 500 | i | default amount of rows to select in a single query during a TTL job
+ sql.ttl.default_select_rate_limit | 0 | i | default select rate limit for all TTL jobs. Use 0 to signify no rate limit.
sql.ttl.job.enabled | false | b | whether the TTL job is enabled
-(5 rows)
+(6 rows)
~~~
## Common errors
diff --git a/src/current/v25.2/row-level-ttl.md b/src/current/v25.2/row-level-ttl.md
index edac9170806..32f146e3668 100644
--- a/src/current/v25.2/row-level-ttl.md
+++ b/src/current/v25.2/row-level-ttl.md
@@ -146,10 +146,10 @@ The settings that control the behavior of Row-Level TTL are provided using [stor
| `ttl_expiration_expression` | **Recommended**. SQL expression that defines the TTL expiration. Must evaluate to a [`TIMESTAMPTZ`]({% link {{ page.version.version }}/timestamp.md %}). This and/or [`ttl_expire_after`](#param-ttl-expire-after) are required to enable TTL. This parameter is useful when you want to set the TTL for individual rows in the table. For an example, see [Create a table with a `ttl_expiration_expression`](#create-a-table-with-a-ttl_expiration_expression). | N/A |
| `ttl_expire_after` | The [interval]({% link {{ page.version.version }}/interval.md %}) when a TTL will expire. This and/or [`ttl_expiration_expression`](#param-ttl-expiration-expression) are required to enable TTL. Minimum value: `'1 microsecond'`. | N/A |
| `ttl` | Signifies if a TTL is active. Automatically set. | N/A |
-| `ttl_select_batch_size` | How many rows to [select]({% link {{ page.version.version }}/select-clause.md %}) at one time during the row expiration check. Default: 500. Minimum: 1. | `sql.ttl.default_select_batch_size` |
-| `ttl_delete_batch_size` | How many rows to [delete]({% link {{ page.version.version }}/delete.md %}) at a time. Default: 100. Minimum: 1. | `sql.ttl.default_delete_batch_size` |
-| `ttl_select_rate_limit` | Maximum number of rows to be selected per second (rate limit). Default: 0 (no limit).
Note: The rate limit is applied per leaseholder per table. In practice, it will vary based on the number of [ranges]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-range) and [leaseholders]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-leaseholder).
For example, if this variable is set to 500, and a table `public.foo` has its ranges spread across 3 leaseholders, then the cluster-wide rate limit for `public.foo` is 500 x 3 = 1500.
To determine the number of leaseholders for some table `public.bar` on CockroachDB v23.1+, issue the following query against the output of [`SHOW RANGES ... WITH DETAILS`]({% link {{ page.version.version }}/show-ranges.md %}#show-ranges-for-a-table-with-details):
`SELECT count(DISTINCT lease_holder) FROM [SHOW RANGES FROM TABLE public.bar WITH DETAILS];` | `sql.ttl.default_select_rate_limit` |
-| `ttl_delete_rate_limit` | Maximum number of rows to be deleted per second (rate limit). Default: 100 (set to 0 for no limit).
Note: The rate limit is applied per leaseholder per table. In practice, it will vary based on the number of [ranges]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-range) and [leaseholders]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-leaseholder).
For example, if this variable is set to 500, and a table `public.foo` has its ranges spread across 3 leaseholders, then the cluster-wide rate limit for `public.foo` is 500 x 3 = 1500.
To determine the number of leaseholders for some table `public.bar` on CockroachDB v23.1+, issue the following query against the output of [`SHOW RANGES ... WITH DETAILS`]({% link {{ page.version.version }}/show-ranges.md %}#show-ranges-for-a-table-with-details):
`SELECT count(DISTINCT lease_holder) FROM [SHOW RANGES FROM TABLE public.bar WITH DETAILS];` | `sql.ttl.default_delete_rate_limit` |
+| `ttl_select_batch_size` | How many rows to [select]({% link {{ page.version.version }}/select-clause.md %}) at one time during the row expiration check. Defaults to the value of the associated cluster setting if unset. | `sql.ttl.default_select_batch_size`
Default: 500. Minimum: 1. |
+| `ttl_delete_batch_size` | How many rows to [delete]({% link {{ page.version.version }}/delete.md %}) at a time. Defaults to the value of the associated cluster setting if unset.| `sql.ttl.default_delete_batch_size`
Default: 100. Minimum: 1. |
+| `ttl_select_rate_limit` | Maximum number of rows to be selected per second (rate limit). Defaults to the value of the associated cluster setting if unset.
Note: The rate limit is applied per leaseholder per table. In practice, it will vary based on the number of [ranges]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-range) and [leaseholders]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-leaseholder).
For example, if this variable is set to 500, and a table `public.foo` has its ranges spread across 3 leaseholders, then the cluster-wide rate limit for `public.foo` is 500 x 3 = 1500.
To determine the number of leaseholders for some table `public.bar` on CockroachDB v23.1+, issue the following query against the output of [`SHOW RANGES ... WITH DETAILS`]({% link {{ page.version.version }}/show-ranges.md %}#show-ranges-for-a-table-with-details):
`SELECT count(DISTINCT lease_holder) FROM [SHOW RANGES FROM TABLE public.bar WITH DETAILS];` | `sql.ttl.default_select_rate_limit`
Default: 0. Minimum: 0 (unlimited).|
+| `ttl_delete_rate_limit` | Maximum number of rows to be deleted per second (rate limit). Defaults to the value of the associated cluster setting if unset.
Note: The rate limit is applied per leaseholder per table. In practice, it will vary based on the number of [ranges]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-range) and [leaseholders]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-leaseholder).
For example, if this variable is set to 500, and a table `public.foo` has its ranges spread across 3 leaseholders, then the cluster-wide rate limit for `public.foo` is 500 x 3 = 1500.
To determine the number of leaseholders for some table `public.bar` on CockroachDB v23.1+, issue the following query against the output of [`SHOW RANGES ... WITH DETAILS`]({% link {{ page.version.version }}/show-ranges.md %}#show-ranges-for-a-table-with-details):
`SELECT count(DISTINCT lease_holder) FROM [SHOW RANGES FROM TABLE public.bar WITH DETAILS];` | `sql.ttl.default_delete_rate_limit`
Default: 100. Minimum: 0 (unlimited).|
| `ttl_row_stats_poll_interval` | If set, counts rows and expired rows on the table to report as Prometheus metrics while the TTL job is running. Unset by default, meaning no stats are fetched and reported. | N/A |
| `ttl_pause` | If set, stops the TTL job from executing. | N/A |
| `ttl_job_cron` | Frequency at which the TTL job runs, specified using [CRON syntax](https://cron.help). Default: `'@daily'` (was `'@hourly'`). | N/A |
@@ -516,8 +516,9 @@ WITH x AS (SHOW CLUSTER SETTINGS) SELECT * FROM x WHERE variable LIKE 'sql.ttl.%
sql.ttl.default_delete_batch_size | 100 | i | default amount of rows to delete in a single query during a TTL job
sql.ttl.default_delete_rate_limit | 100 | i | default delete rate limit for all TTL jobs. Use 0 to signify no rate limit.
sql.ttl.default_select_batch_size | 500 | i | default amount of rows to select in a single query during a TTL job
+ sql.ttl.default_select_rate_limit | 0 | i | default select rate limit for all TTL jobs. Use 0 to signify no rate limit.
sql.ttl.job.enabled | false | b | whether the TTL job is enabled
-(5 rows)
+(6 rows)
~~~
## Common errors
diff --git a/src/current/v25.3/row-level-ttl.md b/src/current/v25.3/row-level-ttl.md
index ecef249544c..9e549d9ab6f 100644
--- a/src/current/v25.3/row-level-ttl.md
+++ b/src/current/v25.3/row-level-ttl.md
@@ -146,10 +146,10 @@ The settings that control the behavior of Row-Level TTL are provided using [stor
| `ttl_expiration_expression` | **Recommended**. SQL expression that defines the TTL expiration. Must evaluate to a [`TIMESTAMPTZ`]({% link {{ page.version.version }}/timestamp.md %}). This and/or [`ttl_expire_after`](#param-ttl-expire-after) are required to enable TTL. This parameter is useful when you want to set the TTL for individual rows in the table. For an example, see [Create a table with a `ttl_expiration_expression`](#create-a-table-with-a-ttl_expiration_expression). | N/A |
| `ttl_expire_after` | The [interval]({% link {{ page.version.version }}/interval.md %}) when a TTL will expire. This and/or [`ttl_expiration_expression`](#param-ttl-expiration-expression) are required to enable TTL. Minimum value: `'1 microsecond'`. | N/A |
| `ttl` | Signifies if a TTL is active. Automatically set. | N/A |
-| `ttl_select_batch_size` | How many rows to [select]({% link {{ page.version.version }}/select-clause.md %}) at one time during the row expiration check. Default: 500. Minimum: 1. | `sql.ttl.default_select_batch_size` |
-| `ttl_delete_batch_size` | How many rows to [delete]({% link {{ page.version.version }}/delete.md %}) at a time. Default: 100. Minimum: 1. | `sql.ttl.default_delete_batch_size` |
-| `ttl_select_rate_limit` | Maximum number of rows to be selected per second (rate limit). Default: 0 (no limit).
Note: The rate limit is applied per leaseholder per table. In practice, it will vary based on the number of [ranges]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-range) and [leaseholders]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-leaseholder).
For example, if this variable is set to 500, and a table `public.foo` has its ranges spread across 3 leaseholders, then the cluster-wide rate limit for `public.foo` is 500 x 3 = 1500.
To determine the number of leaseholders for some table `public.bar` on CockroachDB v23.1+, issue the following query against the output of [`SHOW RANGES ... WITH DETAILS`]({% link {{ page.version.version }}/show-ranges.md %}#show-ranges-for-a-table-with-details):
`SELECT count(DISTINCT lease_holder) FROM [SHOW RANGES FROM TABLE public.bar WITH DETAILS];` | `sql.ttl.default_select_rate_limit` |
-| `ttl_delete_rate_limit` | Maximum number of rows to be deleted per second (rate limit). Default: 100 (set to 0 for no limit).
Note: The rate limit is applied per leaseholder per table. In practice, it will vary based on the number of [ranges]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-range) and [leaseholders]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-leaseholder).
For example, if this variable is set to 500, and a table `public.foo` has its ranges spread across 3 leaseholders, then the cluster-wide rate limit for `public.foo` is 500 x 3 = 1500.
To determine the number of leaseholders for some table `public.bar` on CockroachDB v23.1+, issue the following query against the output of [`SHOW RANGES ... WITH DETAILS`]({% link {{ page.version.version }}/show-ranges.md %}#show-ranges-for-a-table-with-details):
`SELECT count(DISTINCT lease_holder) FROM [SHOW RANGES FROM TABLE public.bar WITH DETAILS];` | `sql.ttl.default_delete_rate_limit` |
+| `ttl_select_batch_size` | How many rows to [select]({% link {{ page.version.version }}/select-clause.md %}) at one time during the row expiration check. Defaults to the value of the associated cluster setting if unset. | `sql.ttl.default_select_batch_size`
Default: 500. Minimum: 1. |
+| `ttl_delete_batch_size` | How many rows to [delete]({% link {{ page.version.version }}/delete.md %}) at a time. Defaults to the value of the associated cluster setting if unset.| `sql.ttl.default_delete_batch_size`
Default: 100. Minimum: 1. |
+| `ttl_select_rate_limit` | Maximum number of rows to be selected per second (rate limit). Defaults to the value of the associated cluster setting if unset.
Note: The rate limit is applied per leaseholder per table. In practice, it will vary based on the number of [ranges]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-range) and [leaseholders]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-leaseholder).
For example, if this variable is set to 500, and a table `public.foo` has its ranges spread across 3 leaseholders, then the cluster-wide rate limit for `public.foo` is 500 x 3 = 1500.
To determine the number of leaseholders for some table `public.bar` on CockroachDB v23.1+, issue the following query against the output of [`SHOW RANGES ... WITH DETAILS`]({% link {{ page.version.version }}/show-ranges.md %}#show-ranges-for-a-table-with-details):
`SELECT count(DISTINCT lease_holder) FROM [SHOW RANGES FROM TABLE public.bar WITH DETAILS];` | `sql.ttl.default_select_rate_limit`
Default: 0. Minimum: 0 (unlimited).|
+| `ttl_delete_rate_limit` | Maximum number of rows to be deleted per second (rate limit). Defaults to the value of the associated cluster setting if unset.
Note: The rate limit is applied per leaseholder per table. In practice, it will vary based on the number of [ranges]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-range) and [leaseholders]({% link {{ page.version.version }}/architecture/overview.md %}#architecture-leaseholder).
For example, if this variable is set to 500, and a table `public.foo` has its ranges spread across 3 leaseholders, then the cluster-wide rate limit for `public.foo` is 500 x 3 = 1500.
To determine the number of leaseholders for some table `public.bar` on CockroachDB v23.1+, issue the following query against the output of [`SHOW RANGES ... WITH DETAILS`]({% link {{ page.version.version }}/show-ranges.md %}#show-ranges-for-a-table-with-details):
`SELECT count(DISTINCT lease_holder) FROM [SHOW RANGES FROM TABLE public.bar WITH DETAILS];` | `sql.ttl.default_delete_rate_limit`
Default: 100. Minimum: 0 (unlimited).|
| `ttl_row_stats_poll_interval` | If set, counts rows and expired rows on the table to report as Prometheus metrics while the TTL job is running. Unset by default, meaning no stats are fetched and reported. | N/A |
| `ttl_pause` | If set, stops the TTL job from executing. | N/A |
| `ttl_job_cron` | Frequency at which the TTL job runs, specified using [CRON syntax](https://cron.help). Default: `'@daily'` (was `'@hourly'`). | N/A |
@@ -516,8 +516,9 @@ WITH x AS (SHOW CLUSTER SETTINGS) SELECT * FROM x WHERE variable LIKE 'sql.ttl.%
sql.ttl.default_delete_batch_size | 100 | i | default amount of rows to delete in a single query during a TTL job
sql.ttl.default_delete_rate_limit | 100 | i | default delete rate limit for all TTL jobs. Use 0 to signify no rate limit.
sql.ttl.default_select_batch_size | 500 | i | default amount of rows to select in a single query during a TTL job
+ sql.ttl.default_select_rate_limit | 0 | i | default select rate limit for all TTL jobs. Use 0 to signify no rate limit.
sql.ttl.job.enabled | false | b | whether the TTL job is enabled
-(5 rows)
+(6 rows)
~~~
## Common errors