# What's New in v25.2

CockroachDB v25.2 is a required Regular Release.

Refer to Major release types before installing or upgrading for release timing and support details. To learn what's new in this release, refer to its Feature Highlights.

On this page, you can read about changes and find downloads for all production and testing releases of CockroachDB v25.2

- For key feature enhancements in v25.2 and other upgrade considerations, refer to the notes for v25.2.0.

- For details about release types, naming, and licensing, refer to the Releases page.

- Be sure to also review the Release Support Policy.

- After downloading a supported CockroachDB binary, learn how to install CockroachDB or upgrade your cluster.

Get future release notes emailed to you:

Thanks!

## v25.2.10

Release Date: December 12, 2025

### Downloads

Note:

This version is currently available only for select CockroachDB Cloud clusters. To request to upgrade a CockroachDB self-hosted cluster to this version, contact support.

### Changelog

View a detailed changelog on GitHub: v25.2.9...v25.2.10

### DB Console changes

- The background (elastic) store graphs for exhausted duration, and the wait duration histogram, have been separated from the foreground (regular) graphs. #156868

### Bug fixes

- A mechanism that prevents unsafe replication changes from causing loss of quorum now functions correctly. An internal function has been fixed to properly return errors, enhancing the reliability of replication safeguards. #156521
- Fixed a bug that could cause internal errors for queries using generic query plans with `NULL` placeholder values. #156977

### Performance improvements

- The cost of generic query plans is now calculated based on worst-case selectivities for placeholder equalities (e.g., `x = $1`). This reduces the chance of suboptimal generic query plans being chosen when `plan_cache_mode=auto`. #156797

### Miscellaneous

- Span config reconciliation jobs no longer fail on the destination after failover from a PCR stream of a system virtual cluster. #156810

## v25.2.9

Release Date: November 14, 2025

### Downloads

Note:

Experimental downloads are not qualified for production use and not eligible for support or uptime SLA commitments, whether they are for testing releases or production releases.

Operating System | Architecture | Full executable | SQL-only executable
--- | --- | --- | ---
Linux | Intel | cockroach-v25.2.9.linux-amd64.tgz (SHA256) | cockroach-sql-v25.2.9.linux-amd64.tgz (SHA256)
ARM | cockroach-v25.2.9.linux-arm64.tgz (SHA256) | cockroach-sql-v25.2.9.linux-arm64.tgz (SHA256)
Mac (Experimental) | Intel | cockroach-v25.2.9.darwin-10.9-amd64.tgz (SHA256) | cockroach-sql-v25.2.9.darwin-10.9-amd64.tgz (SHA256)
ARM | cockroach-v25.2.9.darwin-11.0-arm64.tgz (SHA256) | cockroach-sql-v25.2.9.darwin-11.0-arm64.tgz (SHA256)
Windows (Experimental) | Intel | cockroach-v25.2.9.windows-6.2-amd64.zip (SHA256) | cockroach-sql-v25.2.9.windows-6.2-amd64.zip (SHA256)

### Docker image

Multi-platform images include support for both Intel and ARM. Multi-platform images do not take up additional space on your Docker host.

Within the multi-platform image, both Intel and ARM images are generally available for production use.

To download the Docker image:

    docker pull cockroachdb/cockroach:v25.2.9

### Source tag

To view or download the source code for CockroachDB v25.2.9 on Github, visit v25.2.9 source tag.

### Changelog

View a detailed changelog on GitHub: v25.2.8...v25.2.9

### SQL language changes

- Added the `sql.statements.rows_read.count` metric that counts the number of index rows read by SQL statements. #156595
- Added the `sql.statements.index_rows_written.count` metric that counts the number of primary and secondary index rows modified by SQL statements. #156595
- Added the `sql.statements.index_bytes_written.count` metric that counts the number of primary and secondary index bytes modified by SQL statements. #156595
- Added the `sql.statements.bytes_read.count` metric that counts the number of bytes scanned by SQL statements. #156595

### Bug fixes

- Fixed a bug where changefeeds using CDC queries could sometimes unexpectedly fail after a schema change with a descriptor retrieval error. #156552

## v25.2.8

Release Date: October 30, 2025

### Downloads

Note:

Experimental downloads are not qualified for production use and not eligible for support or uptime SLA commitments, whether they are for testing releases or production releases.

Operating System | Architecture | Full executable | SQL-only executable
--- | --- | --- | ---
Linux | Intel | cockroach-v25.2.8.linux-amd64.tgz (SHA256) | cockroach-sql-v25.2.8.linux-amd64.tgz (SHA256)
ARM | cockroach-v25.2.8.linux-arm64.tgz (SHA256) | cockroach-sql-v25.2.8.linux-arm64.tgz (SHA256)
Mac (Experimental) | Intel | cockroach-v25.2.8.darwin-10.9-amd64.tgz (SHA256) | cockroach-sql-v25.2.8.darwin-10.9-amd64.tgz (SHA256)
ARM | cockroach-v25.2.8.darwin-11.0-arm64.tgz (SHA256) | cockroach-sql-v25.2.8.darwin-11.0-arm64.tgz (SHA256)
Windows (Experimental) | Intel | cockroach-v25.2.8.windows-6.2-amd64.zip (SHA256) | cockroach-sql-v25.2.8.windows-6.2-amd64.zip (SHA256)

### Docker image

Multi-platform images include support for both Intel and ARM. Multi-platform images do not take up additional space on your Docker host.

Within the multi-platform image, both Intel and ARM images are generally available for production use.

To download the Docker image:

    docker pull cockroachdb/cockroach:v25.2.8

### Source tag

To view or download the source code for CockroachDB v25.2.8 on Github, visit v25.2.8 source tag.

### Changelog

View a detailed changelog on GitHub: v25.2.7...v25.2.8

### Operational changes

- In order to selectively capture traces for transactions running in an active workload without having to capture them via statement diagnostic bundles, customers can now use the `sql.trace.txn.sample_rate` cluster setting to enable tracing for a fraction of their workload. The `sql.trace.txn.enable_threshold` will still need to be set to a positive value to provide a filter for how slow a transaction needs to be after being sampled to merit emitting a trace. Traces are emitted to the `SQL_EXEC` logging channel. #156409

### Bug fixes

- Fixed a bug in the `cockroach node drain` command where draining a node using virtual clusters (such as clusters running Physical Cluster Replication (PCR)) could return before the drain was complete, possibly resulting in shutting down the node while it still had active SQL clients and range leases. #156312

## v25.2.7

Release Date: October 17, 2025

### Downloads

Note:

Experimental downloads are not qualified for production use and not eligible for support or uptime SLA commitments, whether they are for testing releases or production releases.

Operating System | Architecture | Full executable | SQL-only executable
--- | --- | --- | ---
Linux | Intel | cockroach-v25.2.7.linux-amd64.tgz (SHA256) | cockroach-sql-v25.2.7.linux-amd64.tgz (SHA256)
ARM | cockroach-v25.2.7.linux-arm64.tgz (SHA256) | cockroach-sql-v25.2.7.linux-arm64.tgz (SHA256)
Mac (Experimental) | Intel | cockroach-v25.2.7.darwin-10.9-amd64.tgz (SHA256) | cockroach-sql-v25.2.7.darwin-10.9-amd64.tgz (SHA256)
ARM | cockroach-v25.2.7.darwin-11.0-arm64.tgz (SHA256) | cockroach-sql-v25.2.7.darwin-11.0-arm64.tgz (SHA256)
Windows (Experimental) | Intel | cockroach-v25.2.7.windows-6.2-amd64.zip (SHA256) | cockroach-sql-v25.2.7.windows-6.2-amd64.zip (SHA256)

### Docker image

Multi-platform images include support for both Intel and ARM. Multi-platform images do not take up additional space on your Docker host.

Within the multi-platform image, both Intel and ARM images are generally available for production use.

To download the Docker image:

    docker pull cockroachdb/cockroach:v25.2.7

### Source tag

To view or download the source code for CockroachDB v25.2.7 on Github, visit v25.2.7 source tag.

### Changelog

View a detailed changelog on GitHub: v25.2.6...v25.2.7

### Bug fixes

- Fixed a bug where an `INSERT` statement could fail with a type checking error while adding a `BIT(n)` column. #152964
- Fixed a bug where index creation could fail due to validation errors if the schema change was retried or paused/resumed during the backfill. #153596
- Fixed a bug introduced in v25.1.0 that would cause a node panic if a `SIGINT` signal was sent during the execution of a `CHECK EXTERNAL CONNECTION` command. #153601
- Fixed a bug where `ALTER POLICY` was incorrectly dropping dependency tracking for functions, sequences, or types in policy expressions. #153808
- Fixed a runtime error that could be hit if a new secondary index had a name collision with a primary index. #154015
- Fixed a bug that caused panics when executing `COPY` into a table with hidden columns and expression indexes. The panic only occurred when the session setting `expect_and_ignore_not_visible_columns_in_copy` was enabled. This bug was introduced with `expect_and_ignore_not_visible_columns_in_copy` in v22.1.0. #154290
- Disabled the `kv.lock_table.unreplicated_lock_reliability.split.enabled` feature, which could lead to a node crash. #155418
- Fixed a bug where the presence of duplicate temporary tables in a backup caused the restore to fail with an error containing the text `restoring table desc and namespace entries: table already exists`. #154398

## v25.2.6

Release Date: September 22, 2025

### Downloads

Note:

Experimental downloads are not qualified for production use and not eligible for support or uptime SLA commitments, whether they are for testing releases or production releases.

Operating System | Architecture | Full executable | SQL-only executable
--- | --- | --- | ---
Linux | Intel | cockroach-v25.2.6.linux-amd64.tgz (SHA256) | cockroach-sql-v25.2.6.linux-amd64.tgz (SHA256)
ARM | cockroach-v25.2.6.linux-arm64.tgz (SHA256) | cockroach-sql-v25.2.6.linux-arm64.tgz (SHA256)
Mac (Experimental) | Intel | cockroach-v25.2.6.darwin-10.9-amd64.tgz (SHA256) | cockroach-sql-v25.2.6.darwin-10.9-amd64.tgz (SHA256)
ARM | cockroach-v25.2.6.darwin-11.0-arm64.tgz (SHA256) | cockroach-sql-v25.2.6.darwin-11.0-arm64.tgz (SHA256)
Windows (Experimental) | Intel | cockroach-v25.2.6.windows-6.2-amd64.zip (SHA256) | cockroach-sql-v25.2.6.windows-6.2-amd64.zip (SHA256)

### Docker image

Multi-platform images include support for both Intel and ARM. Multi-platform images do not take up additional space on your Docker host.

Within the multi-platform image, both Intel and ARM images are generally available for production use.

To download the Docker image:

    docker pull cockroachdb/cockroach:v25.2.6

### Source tag

To view or download the source code for CockroachDB v25.2.6 on Github, visit v25.2.6 source tag.

### Changelog

View a detailed changelog on GitHub: v25.2.5...v25.2.6

### SQL language changes

- Added a new session variable, `disable_optimizer_rules`, which allows users to provide a comma-separated list of optimizer rules to disable during query optimization. This allows users to avoid rules that are known to create a suboptimal query plan for specific queries. #152349
- When `sql_safe_updates` is enabled, the `ALTER TABLE ... LOCALITY` statement will be blocked when trying to convert an existing table to `REGIONAL BY ROW`, unless a region column has been added to the table. This protects against undesired behavior that caused `UPDATE` or `DELETE` statements to fail against the table while the locality change was in progress. #152600

### Operational changes

- Updated TTL job replanning to be less sensitive by focusing specifically on detecting when nodes become unavailable rather than reacting to all plan differences. The cluster setting `sql.ttl.replan_flow_threshold` may have been set to `0` to work around the TTL replanner being too sensitive; this fix will alleviate that and any instance that had set `replan_flow_threshold` to `0` can be reset back to the default. #151485

### Bug fixes

- Fixed a bug where `debug.zip` files collected from clusters with `disallow_full_table_scans` enabled were missing system table data. #151224
- Addressed a bug on `schema_locked` tables when a column is dropped, and `schema_locked` is toggled for the user. #151528
- Fixed a bug that could cause excessive memory allocations when compacting timeseries keys. #151814
- Fixed a bug where `DROP USER` succeeded even though a role owned default privileges, which could leave invalid privilege entries in the system. #151879
- Previously, CockroachDB could hit an error `ERROR: span with results after resume span...` when evaluating some queries with `ORDER BY ... DESC` in an edge case. This bug was present since v22.1 and is now fixed. #152184
- Fixed a bug where `SHOW TABLES` would show inaccurate row counts if the most recent statistics collection was partial. #152186
- Fixed a bug where updating column default expressions would incorrectly remove sequence ownerships for the affected column. #152314
- Fixed a bug that allowed foreign-key violations to result from some combinations of concurrent `READ COMMITTED` and `SERIALIZABLE` transactions. If both `SERIALIZABLE` and weaker-isolation transactions will concurrently modify rows involved in foreign-key relationships, the `SERIALIZABLE` transactions must have the following session variables set in order to prevent any possible foreign-key violations:
  - `SET enable_implicit_fk_locking_for_serializable = on;`
  - `SET enable_shared_locking_for_serializable = on;`
  - `SET enable_durable_locking_for_serializable = on;` #152375
- Added an automatic repair for dangling or invalid entries in the `system.comments` table. #152471
- Added the `use_soft_limit_for_distribute_scan` session variable (default: `false`), which controls whether CockroachDB uses the soft row count estimate when deciding whether an execution plan should be distributed. In v25.1, the physical planning heuristics were changed such that large constrained table scans, estimated to scan at least 10,000 rows (controlled via `distribute_scan_row_count_threshold`), would force plan distribution when `distsql=auto`. However, if the scan had a "soft limit" CockroachDB would still use the full estimate (for example, `10,000` in `estimated row count: 100–10,000`), sometimes unnecessarily distributing queries and increasing latency. The `use_soft_limit_for_distribute_scan` session variable addresses this by allowing the planner to use the soft limit when deciding whether a scan is "large". #152559
- Fixed a bug where views could not reference the `crdb_region` column from their underlying tables in expressions. #152679

### Performance improvements

- Lookup joins can now be used on tables with virtual columns even if the type of the search argument is not identical to the column type referenced in the virtual column. #152631

### Miscellaneous

- Tunes S3 client retry behavior to be more reliable in the presence of correlated errors. #151874

## v25.2.5

Release Date: August 22, 2025

### Downloads

Note:

Experimental downloads are not qualified for production use and not eligible for support or uptime SLA commitments, whether they are for testing releases or production releases.

Operating System | Architecture | Full executable | SQL-only executable
--- | --- | --- | ---
Linux | Intel | cockroach-v25.2.5.linux-amd64.tgz (SHA256) | cockroach-sql-v25.2.5.linux-amd64.tgz (SHA256)
ARM | cockroach-v25.2.5.linux-arm64.tgz (SHA256) | cockroach-sql-v25.2.5.linux-arm64.tgz (SHA256)
Mac (Experimental) | Intel | cockroach-v25.2.5.darwin-10.9-amd64.tgz (SHA256) | cockroach-sql-v25.2.5.darwin-10.9-amd64.tgz (SHA256)
ARM | cockroach-v25.2.5.darwin-11.0-arm64.tgz (SHA256) | cockroach-sql-v25.2.5.darwin-11.0-arm64.tgz (SHA256)
Windows (Experimental) | Intel | cockroach-v25.2.5.windows-6.2-amd64.zip (SHA256) | cockroach-sql-v25.2.5.windows-6.2-amd64.zip (SHA256)

### Docker image

Multi-platform images include support for both Intel and ARM. Multi-platform images do not take up additional space on your Docker host.

Within the multi-platform image, both Intel and ARM images are generally available for production use.

To download the Docker image:

    docker pull cockroachdb/cockroach:v25.2.5

### Source tag

To view or download the source code for CockroachDB v25.2.5 on Github, visit v25.2.5 source tag.

### Changelog

View a detailed changelog on GitHub: v25.2.4...v25.2.5

### General changes

- Kafka v2 changefeed sinks now support a cluster setting that enables detailed error logging for messages exceeding Kafka v2 size limit. #149829

### Operational changes

- Introduced a cluster setting, `sql.stats.error_on_concurrent_create_stats.enabled`, which modifies how CockroachDB reacts to concurrent auto stats jobs. The default, `true`, maintains the previous behavior. Setting `sql.stats.error_on_concurrent_create_stats.enabled` to `false` will cause the concurrent auto stats job to be skipped with just a log entry and no increased error counters. #149837

### Bug fixes

- Fixed an issue where the mvcc_timestamp field was incorrectly returning zero values when used with CDC queries. The timestamp is now emitted correctly. #147114
- Fixed a bug where database login could fail during LDAP, JWT, or OIDC authentication if the user's external group memberships did not correspond to any existing roles in the database. The login will now succeed, and no roles will be granted or revoked in this scenario. #149747
- Fixed a bug that would cause a `CALL` statement executed via a portal in the extended wire protocol to result in an error like `unknown portal ""` if the stored procedure contained `COMMIT` or `ROLLBACK` statements. The bug had existed since PL/pgSQL transaction control statements were introduced in v24.1. The fix will be off by default in versions prior to v25.3, and can be toggled on by setting `use_proc_txn_control_extended_protocol_fix = true`. #149851
- Fixed a slow memory leak that was introduced in v25.1.8, v25.2.1, v25.2.2, and v25.3 betas. The leak would accumulate whenever a node executed a part of the distributed plan (the gateway node of the plan was not affected), and could only be mitigated by restarting the node. #149919
- Fixed an issue where some SQL metrics were not reported when `server.child_metrics.enabled` was enabled, `server.child_metrics.include_aggregate.enabled` was disabled, and `sql.metrics.application_name.enabled` and `sql.metrics.database_name.enabled` were also disabled. Specifically, metrics with no children now report their aggregate metrics regardless of the `server.child_metrics.include_aggregate.enabled` cluster setting. #149937
- Fixed a bug that would allow a race condition in foreign key cascades under `READ COMMITTED` and `REPEATABLE READ` isolation levels. #150295
- Fixed an issue where discarding zone configs on sequences did not actually remove the configuration. #150359
- Fixed a bug where the entire schema would become inaccessible if a table was referenced as an implicit record type by a user-defined function (UDF) while the table was undergoing an `IMPORT`. #150439
- Fixed invalid zone configurations that were generated when adding a super region to a 3-region database with a secondary region and region survivability. Previously, this could result in assigning more than the allowed number of replicas. #150619
- Fixed a bug that could cause some errors returned by attempts to upload backup data to external storage providers to be undetected, potentially causing incomplete backups. #151082
- Fixed a memory accounting issue in the client certificate cache that caused multiple allocations to be reported for the same certificate. The cache now accurately tracks memory usage and includes a safeguard to prevent it from negatively affecting SQL operations. #151146
- Previously, CockroachDB could encounter an internal error `trying to add a column of UNKNOWN type at ...` in rare cases when handling `CASE` or `OR` operations. This bug was present since v20.2 and is now fixed. #151161
- Previously, CockroachDB could hit an error `ERROR: span with results after resume span...` when evaluating some queries with `ORDER BY ... DESC` in an edge case. This bug was present since v22.1 and is now fixed. #152185

### Miscellaneous

- Upgrade to Go 1.23.11 #150988

## v25.2.4

Release Date: August 1, 2025

### Downloads

Note:

Experimental downloads are not qualified for production use and not eligible for support or uptime SLA commitments, whether they are for testing releases or production releases.

Operating System | Architecture | Full executable | SQL-only executable
--- | --- | --- | ---
Linux | Intel | cockroach-v25.2.4.linux-amd64.tgz (SHA256) | cockroach-sql-v25.2.4.linux-amd64.tgz (SHA256)
ARM | cockroach-v25.2.4.linux-arm64.tgz (SHA256) | cockroach-sql-v25.2.4.linux-arm64.tgz (SHA256)
Mac (Experimental) | Intel | cockroach-v25.2.4.darwin-10.9-amd64.tgz (SHA256) | cockroach-sql-v25.2.4.darwin-10.9-amd64.tgz (SHA256)
ARM | cockroach-v25.2.4.darwin-11.0-arm64.tgz (SHA256) | cockroach-sql-v25.2.4.darwin-11.0-arm64.tgz (SHA256)
Windows (Experimental) | Intel | cockroach-v25.2.4.windows-6.2-amd64.zip (SHA256) | cockroach-sql-v25.2.4.windows-6.2-amd64.zip (SHA256)

### Docker image

Multi-platform images include support for both Intel and ARM. Multi-platform images do not take up additional space on your Docker host.

Within the multi-platform image, both Intel and ARM images are generally available for production use.

To download the Docker image:

    docker pull cockroachdb/cockroach:v25.2.4

### Source tag

To view or download the source code for CockroachDB v25.2.4 on Github, visit v25.2.4 source tag.

### Changelog

View a detailed changelog on GitHub: v25.2.3...v25.2.4

### Bug fixes

- Fixed a bug that could cause some errors returned by attempts to upload backup data to external storage providers to be undetected, potentially causing incomplete backups. #151095

## v25.2.3

Release Date: July 28, 2025

### Downloads

Note:

Experimental downloads are not qualified for production use and not eligible for support or uptime SLA commitments, whether they are for testing releases or production releases.

Operating System | Architecture | Full executable | SQL-only executable
--- | --- | --- | ---
Linux | Intel | cockroach-v25.2.3.linux-amd64.tgz (SHA256) | cockroach-sql-v25.2.3.linux-amd64.tgz (SHA256)
ARM | cockroach-v25.2.3.linux-arm64.tgz (SHA256) | cockroach-sql-v25.2.3.linux-arm64.tgz (SHA256)
Mac (Experimental) | Intel | cockroach-v25.2.3.darwin-10.9-amd64.tgz (SHA256) | cockroach-sql-v25.2.3.darwin-10.9-amd64.tgz (SHA256)
ARM | cockroach-v25.2.3.darwin-11.0-arm64.tgz (SHA256) | cockroach-sql-v25.2.3.darwin-11.0-arm64.tgz (SHA256)
Windows (Experimental) | Intel | cockroach-v25.2.3.windows-6.2-amd64.zip (SHA256) | cockroach-sql-v25.2.3.windows-6.2-amd64.zip (SHA256)

### Docker image

Multi-platform images include support for both Intel and ARM. Multi-platform images do not take up additional space on your Docker host.

Within the multi-platform image, both Intel and ARM images are generally available for production use.

To download the Docker image:

    docker pull cockroachdb/cockroach:v25.2.3

### Source tag

To view or download the source code for CockroachDB v25.2.3 on Github, visit v25.2.3 source tag.

### Changelog

View a detailed changelog on GitHub: v25.2.2...v25.2.3

### General changes

- Changefeeds emitting to Kafka sinks that were created in CockroachDB v24.2.1+, or v23.2.10+ and v24.1.4+ with the `changefeed.new_kafka_sink.enabled` cluster setting enabled now include the message key, size, and MVCC timestamp in message too large error logs. #147929

### SQL language changes

- Added the metrics `sql.txn.auto_retry.count` and `sql.statements.auto_retry.count`, which count the number of automatic retries of SQL transactions and statements, respectively, within the database. These metrics differ from the related `txn.restarts.*` metrics, which count retryable errors emitted by the KV layer that must be retried. The new `sql.txn.auto_retry.count` and `sql.statements.auto_retry.count` metrics count auto-retry actions taken by the SQL layer in response to some of those retryable errors. #148207
- Added a session variable `initial_retry_backoff_for_read_committed` that controls the initial backoff duration when retrying an individual statement in an explicit `READ COMMITTED` transaction. A duration of `0` disables exponential backoff. If a statement in an explicit `READ COMMITTED` transaction is failing with the `40001` error `ERROR: restart transaction: read committed retry limit exceeded; set by max_retries_for_read_committed=...`, then you should set `initial_retry_backoff_for_read_committed` to a duration proportional to the typical execution time of the statement (in addition to also increasing `max_retries_for_read_committed`). #148207

### DB Console changes

- Updated the "Learn more" link on the Hot Ranges page to direct users to a newer, more comprehensive reference guide about hotspots. #148522

### Bug fixes

- Fixed a data race in the `cloudstorage` sink. #147163
- Fixed a bug where searching a vector with a query vector that doesn't match the dimensions of the vector column in the table would cause a node to crash. #147875
- Fixed a bug where functions lost their row-level security (RLS) policy backreferences, leading to schema change failures. #147905
- Fixed an error in `crdb_internal.table_spans` that could occur when a table's schema had been dropped. #147977
- Fixed a bug where adding multiple columns in a single statement with `AddGeometryColumn` would cause runtime errors. #148146
- Fixed a bug where `libpq` clients using the async API could hang with large result sets (Python: psycopg; Ruby: ActiveRecord, ruby-pg). #148468
- Previously, CockroachDB could hit an internal error when performing a `DELETE`, `UPDATE`, or `UPSERT` where the initial scan of the mutation is locking and is on a table different from the one being mutated. A possible workaround was `SET enable_implicit_select_for_update = false`, but this could increase contention. The bug was introduced in v25.2 and is now fixed. #149301

- The `RESET ALL` statement no longer affects the following session variables:

  - `is_superuser`
  - `role`
  - `session_authorization`
  - `transaction_isolation`
  - `transaction_priority`
  - `transaction_status`
  - `transaction_read_only`

  This better matches PostgreSQL behavior for `RESET ALL`. In addition, the `DISCARD ALL` statement no longer errors when `default_transaction_use_follower_reads` is enabled. #149388

- In v25.1, automatic partial statistics collection was enabled by default (by setting the `sql.stats.automatic_partial_collection.enabled` cluster setting to `true`). Partial statistics collection may encounter certain expected scenarios that were previously reported as failed stats jobs with PostgreSQL error code `55000`. These errors are benign and are no longer reported. Instead, the stats job will be marked as "succeeded," though no new statistics will be created. #149625

- Fixed a slow memory leak that was introduced in v25.1.8, v25.2.1, v25.2.2, and v25.3 betas. The leak would accumulate whenever a node executed a part of the distributed plan (the gateway node of the plan was not affected), and could only be mitigated by restarting the node. #149921

- Fixed an issue where some SQL metrics were not reported when `server.child_metrics.enabled` was enabled, `server.child_metrics.include_aggregate.enabled` was disabled, and `sql.metrics.application_name.enabled` and `sql.metrics.database_name.enabled` were also disabled. Specifically, metrics with no children now report their aggregate metrics regardless of the `server.child_metrics.include_aggregate.enabled` cluster setting. #150185

- Fixed a bug that would allow a race condition in foreign key cascades under `READ COMMITTED` and `REPEATABLE READ` isolation levels. #150338

- Fixed a bug where the entire schema would become inaccessible if a table was referenced as an implicit record type by a user-defined function (UDF) while the table was undergoing an `IMPORT`. #150441

### Miscellaneous

- Restore no longer gets stuck in the reverting state after failed cleanup of dropped temporary system tables. #148485

## v25.2.2

Release Date: June 25, 2025

### Downloads

Note:

Experimental downloads are not qualified for production use and not eligible for support or uptime SLA commitments, whether they are for testing releases or production releases.

Operating System | Architecture | Full executable | SQL-only executable
--- | --- | --- | ---
Linux | Intel | cockroach-v25.2.2.linux-amd64.tgz (SHA256) | cockroach-sql-v25.2.2.linux-amd64.tgz (SHA256)
ARM | cockroach-v25.2.2.linux-arm64.tgz (SHA256) | cockroach-sql-v25.2.2.linux-arm64.tgz (SHA256)
Mac (Experimental) | Intel | cockroach-v25.2.2.darwin-10.9-amd64.tgz (SHA256) | cockroach-sql-v25.2.2.darwin-10.9-amd64.tgz (SHA256)
ARM | cockroach-v25.2.2.darwin-11.0-arm64.tgz (SHA256) | cockroach-sql-v25.2.2.darwin-11.0-arm64.tgz (SHA256)
Windows (Experimental) | Intel | cockroach-v25.2.2.windows-6.2-amd64.zip (SHA256) | cockroach-sql-v25.2.2.windows-6.2-amd64.zip (SHA256)

### Docker image

Multi-platform images include support for both Intel and ARM. Multi-platform images do not take up additional space on your Docker host.

Within the multi-platform image, both Intel and ARM images are generally available for production use.

To download the Docker image:

    docker pull cockroachdb/cockroach:v25.2.2

### Source tag

To view or download the source code for CockroachDB v25.2.2 on Github, visit v25.2.2 source tag.

### Changelog

View a detailed changelog on GitHub: v25.2.1...v25.2.2

### Operational changes

- When `server.telemetry.hot_ranges_stats.enabled` cluster setting is enabled, nodes now log hot ranges every minute if they exceed 250ms of CPU time per second. In multi-tenant deployments, this check occurs every 5 minutes at the cluster level, improving visibility into transient performance issues. #146887
- Added a new metric, `kv.loadsplitter.cleardirection`, which increments when the load-based splitter observes that more than 80% of replica access samples are moving in a single direction (either left/descending or right/ascending). #147169

### DB Console changes

- The Hot Ranges page node filter has been moved out of the main filter container and now filters nodes on the backend to reduce load time. #147778

### Bug fixes

- Fixed a bug that could cause the `cockroach` process to `segfault` when collecting runtime execution traces (typically collected via the Advanced Debug page in the Console). #146886
- Fixed a bug where the `kv.rangefeed.closed_timestamp.slow_ranges` would not be incremented when a rangefeed closed timestamp was slower than the target threshold. #146975
- Fixed a bug that could cause an `AFTER` trigger to fail with `client already committed or rolled back the transaction` if the query also contained foreign-key cascades. The bug had existed since `AFTER` triggers were introduced in v24.3. #146977
- Fixed a bug that caused the SQL Activity > Statement Fingerprint page to fail to load details for statements run with application names containing a `#` character. #147223
- Previously, CockroachDB could incorrectly evaluate the `to_regclass`, `to_regnamespace`, `to_regproc`, `to_regprocedure`, `to_regrole`, and `to_regtype` built-in functions when the query using them was evaluated in a distributed fashion. The bug was introduced with these built-in functions in v23.1 and is now fixed. #147376
- Fixed a bug that caused the optimizer to ignore index hints when optimizing some forms of prepared statements. This could result in one of two unexpected behaviors: a query errors with the message `index cannot be used for this query` when the index can actually be used; or a query uses an index that does not adhere to the hint. The hints relevant to this bug are regular index hints, e.g., `SELECT * FROM tab@index`, `FORCE_INVERTED_INDEX`, and `FORCE_ZIGZAG`. #147417
- Fixed a bug where the `pg_catalog.pg_policy` table could contain duplicate OID values when multiple tables had policies with the same policy ID. All rows in `pg_policy` now have unique OIDs as required. #147438
- Fixed a bug that could cause stable expressions to be folded in cached query plans. The bug could cause stable expressions like `current_setting` to return the wrong result if used in a prepared statement. The bug was introduced in v23.2.22, v24.1.14, v24.3.9, v25.1.2, and the v25.2 alpha. #147460
- Fixed a runtime panic in the `substring_index` function that occurred when the count argument was the minimum 64-bit integer value. #147549
- Fixed a memory leak in index backfill jobs where completed spans were duplicated in memory on each progress update after resuming from a checkpoint. This could cause out-of-memory (OOM) errors when backfilling indexes on large tables with many ranges. This bug affected release version v25.2.0 and pre-release versions v25.2.0-alpha.3 through v25.2.0-rc.1. #147563
- Fixed a bug where prepared statements on schema changes could fail with runtime errors. #147671
- Fixed a bug where `ALTER TABLE` was modifying identity attributes on columns not backed by a sequence. #147711

### Performance improvements

- TTL jobs now respond to cluster topology changes by restarting and rebalancing across available nodes. #147083

### Miscellaneous

- Fixed an issue in Logical Data Replication (LDR) where unique indexes with lower index IDs than the primary key could cause incorrect DLQ entries during replication. #147350

## v25.2.1

Release Date: June 4, 2025

### Downloads

Note:

Experimental downloads are not qualified for production use and not eligible for support or uptime SLA commitments, whether they are for testing releases or production releases.

Operating System | Architecture | Full executable | SQL-only executable
--- | --- | --- | ---
Linux | Intel | cockroach-v25.2.1.linux-amd64.tgz (SHA256) | cockroach-sql-v25.2.1.linux-amd64.tgz (SHA256)
ARM | cockroach-v25.2.1.linux-arm64.tgz (SHA256) | cockroach-sql-v25.2.1.linux-arm64.tgz (SHA256)
Mac (Experimental) | Intel | cockroach-v25.2.1.darwin-10.9-amd64.tgz (SHA256) | cockroach-sql-v25.2.1.darwin-10.9-amd64.tgz (SHA256)
ARM | cockroach-v25.2.1.darwin-11.0-arm64.tgz (SHA256) | cockroach-sql-v25.2.1.darwin-11.0-arm64.tgz (SHA256)
Windows (Experimental) | Intel | cockroach-v25.2.1.windows-6.2-amd64.zip (SHA256) | cockroach-sql-v25.2.1.windows-6.2-amd64.zip (SHA256)

### Docker image

Multi-platform images include support for both Intel and ARM. Multi-platform images do not take up additional space on your Docker host.

Within the multi-platform image, both Intel and ARM images are generally available for production use.

To download the Docker image:

    docker pull cockroachdb/cockroach:v25.2.1

### Source tag

To view or download the source code for CockroachDB v25.2.1 on Github, visit v25.2.1 source tag.

### Changelog

View a detailed changelog on GitHub: v25.2.0...v25.2.1

### SQL language changes

- Added the `sql.metrics.application_name.enabled` and `sql.metrics.database_name.enabled` cluster settings. These settings default to `false`. Set them to `true` to include the application and database name, respectively, in supported metrics. #144932

### Operational changes

- Added the metric `changefeed.checkpoint.timestamp_count` that measures the number of unique timestamps in a changefeed span-level checkpoint. It may be useful to monitor this metric to determine if quantization settings should be changed. #145223
- Logs for hot ranges (`hot_ranges_stats` events) have been moved to the `HEALTH` logging channel. #146762

### DB Console changes

- Schema insights that recommend replacing an index were previously a two-statement command consisting of a `CREATE INDEX` and a `DROP INDEX` statement. When these two DDL statements were run as a single batched command, it was possible for one statement to succeed and one to fail. This is because DDL statements do not have the same atomicity guarantees as other SQL statements in CockroachDB. Index-replacement insights are now a single `CREATE INDEX` statement followed by a comment with additional DDL statements to be run manually: an `ALTER INDEX ... NOT VISIBLE` statement, which makes the old index invisible to the optimizer, followed by a `DROP INDEX` statement that should only be run after making the old index invisible and verifying that workload performance is satisfactory. #145993

### Bug fixes

- Improved the performance of `SHOW CREATE TABLE` on multi-region databases with large numbers of objects. #145004
- Fixed a bug that could cause queries that perform work in parallel to ignore the requested quality-of-service level. Affected operations include lookup joins, DistSQL execution, and foreign-key checks. #145363
- Fixed a bug where running `DROP INDEX` on a hash-sharded index did not properly detect dependencies from functions and procedures on the shard column. This caused the `DROP INDEX` statement to fail with an internal validation error. Now the statement returns a correct error message, and using `DROP INDEX ... CASCADE` works as expected by dropping the dependent functions and procedures. #145386
- Fixed a bug that could lead to schema changes hanging after a cluster recovered from availability issues. #145545
- Previously, on a table with multiple column families, CockroachDB could encounter a `Non-nullable column "‹×›:‹×›" with no value` error in rare cases during table statistics collection. The bug was present since v19.2 and is now fixed. #145576
- Fixed a bug that could cause a row-level TTL job to fail with the error "comparison of two different versions of enum" if an `ENUM` type referenced by the table experienced a schema change. #145917
- Fixed a bug where the physical cluster replication (PCR) reader catalog job could hit validation errors when schema objects had dependencies between them (for example, when a sequence's default expression was being removed). #145999
- Creating a vector index on a table that contains a `NULL` vector value will no longer cause an internal error. #146017
- Row-level security (RLS) `SELECT` policies during `UPDATE` operations are now only applied when referenced columns appear in the `SET` or `WHERE` clauses, matching the behavior of PostgreSQL. This improves compatibility. #146128
- Fixed an internal assertion failure that could occur during operations like `ALTER TYPE` or `ALTER DATABASE ... ADD REGION` when temporary tables were present. #146196
- Fixed incorrect application of row-level security (RLS) `SELECT` policies to `RETURNING` clauses in `INSERT` and `UPDATE` when no table columns were referenced. #146292
- Fixed a bug that prevented `TRUNCATE` from succeeding if any indexes on the table had back-reference dependencies, such as from a view or function referencing the index. #146326
- Fixed a bug that could lead to a node stall. #146409
- Fixed an integer overflow in the `split_part` function when using extremely negative field positions like Go's `math.MinInt64`. #146413
- Fixed a bug where an invalid comment in the `system.comment` table for a schema object could make it inaccessible. #146418
- Fixed a bug where a CockroachDB node could crash when executing `DO` statements that contain currently unsupported DDL statements like `CREATE TYPE` in a non-default configuration (additional logging needed to be enabled, e.g., via the `sql.log.all_statements.enabled` cluster setting). This bug was introduced in v25.1. #146501
- Prevent use of future timestamps when using `AS OF SYSTEM TIME` with `CREATE TABLE ... AS` and materialized views. Previously, such timestamps could cause errors, delays, or hangs. #146605
- Fixed a bug where CockroachDB would not use the vectorized fast path for `COPY` when it was supported. The bug was only present in previous v25.2 releases. #146697
- Fixed an internal error that could be hit when `ADD COLUMN UNIQUE` and `ALTER PRIMARY KEY` were executed within the same transaction. #146743
- Fixed a bug where `ALTER TABLE` operations with multiple commands could generate invalid zone configurations. #146750
- Fixed a bug in v25.2.0 where a vector search operator could drop user-supplied filters if the same vector column was indexed twice and a vector index with no prefix columns was defined after a vector index with prefix columns. #146849
- Fixed an issue where updating child metrics and reinitializing metrics at the same time could cause scrape errors. #147531
- Fixed a runtime panic in the `substring_index` function that occurred when the count argument was the minimum 64-bit integer value. #147550
- Fixed a memory leak in index backfill jobs where completed spans were duplicated in memory on each progress update after resuming from a checkpoint. This could cause out-of-memory (OOM) errors when backfilling indexes on large tables with many ranges. This bug affected release version v25.2.0 and pre-release versions v25.2.0-alpha.3 through v25.2.0-rc.1. #147564

## v25.2.0

Release Date: May 12, 2025

With the release of CockroachDB v25.2, we've added new capabilities to help you migrate, build, and operate more efficiently.

For a summary of the most significant changes, refer to Feature Highlights.

### Downloads

Note:

Experimental downloads are not qualified for production use and not eligible for support or uptime SLA commitments, whether they are for testing releases or production releases.

Operating System | Architecture | Full executable | SQL-only executable
--- | --- | --- | ---
Linux | Intel | cockroach-v25.2.0.linux-amd64.tgz (SHA256) | cockroach-sql-v25.2.0.linux-amd64.tgz (SHA256)
ARM | cockroach-v25.2.0.linux-arm64.tgz (SHA256) | cockroach-sql-v25.2.0.linux-arm64.tgz (SHA256)
Mac (Experimental) | Intel | cockroach-v25.2.0.darwin-10.9-amd64.tgz (SHA256) | cockroach-sql-v25.2.0.darwin-10.9-amd64.tgz (SHA256)
ARM | cockroach-v25.2.0.darwin-11.0-arm64.tgz (SHA256) | cockroach-sql-v25.2.0.darwin-11.0-arm64.tgz (SHA256)
Windows (Experimental) | Intel | cockroach-v25.2.0.windows-6.2-amd64.zip (SHA256) | cockroach-sql-v25.2.0.windows-6.2-amd64.zip (SHA256)

### Docker image

Multi-platform images include support for both Intel and ARM. Multi-platform images do not take up additional space on your Docker host.

Within the multi-platform image, both Intel and ARM images are generally available for production use.

To download the Docker image:

    docker pull cockroachdb/cockroach:v25.2.0

### Source tag

To view or download the source code for CockroachDB v25.2.0 on Github, visit v25.2.0 source tag.

### Changelog

View a detailed changelog on GitHub: v25.2.0-rc.1...v25.2.0

### Feature highlights

This section summarizes the most significant user-facing changes in v25.2.0 and other features recently made available to CockroachDB users across versions. For a complete list of features and changes in v25.2, including bug fixes and performance improvements, refer to the release notes for v25.2 testing releases. You can also search the docs for sections labeled New in v25.2.

- Feature categories

  - CockroachDB Cloud
  - Performance and High Availability
  - Change Data Capture
  - Observability
  - Security
  - SQL
  - Licensing

- Additional information

  - Backward-incompatible changes
  - Key cluster setting changes
  - Deprecations
  - Known limitations
  - Additional resources

#### CockroachDB Cloud

Feature | Availability
--- | ---
Ver. | Self-hosted | Advanced | Standard | Basic
Organize your cloud resources with labels You can categorize your clusters & folders with custom key-value labels. Use labels to add metadata to your clusters, such as environments, teams, or applications. | All* |  |  |  |
Switch between Basic and Standard plans in the Cloud Console You can now change cluster plans between Basic and Standard from the CockroachDB Cloud Console. | All* |  |  |  |

#### Performance and High Availability

Feature | Availability
--- | ---
Ver. | Self-hosted | Advanced | Standard | Basic
Logical Data Replication is now Generally Available (GA) Logical Data Replication (LDR) enables asynchronous data replication between CockroachDB clusters. LDR supports active-active deployments, allowing both source and destination clusters to serve traffic simultaneously, making it ideal for 2DC architectures, low-latency reads/writes, multi-cloud strategies, and workload isolation. For more information, refer to the latest documentation and an earlier blog post. | 25.2 |  |  |  |

#### Change Data Capture

Feature | Availability
--- | ---
Ver. | Self-hosted | Advanced | Standard | Basic
Major reduction in duplicate messages for changefeeds A major improvement to changefeeds significantly reduces the number of duplicate messages emitted during restarts and retries. This means more accurate data delivery, lower processing overhead for downstream consumers, and a smoother experience overall. This improvement is especially beneficial in systems with large tables or uneven processing speeds, where legacy checkpointing often led to unnecessary message duplication. | 25.2 |  |  |  |
Enriched changefeed format for easier integration and richer metadata An enriched changefeed format has been introduced in Preview that aligns with the Debezium message structure, making it significantly easier to integrate CockroachDB into existing CDC pipelines. This new format adds structured metadata and flexibility to the changefeed message body, allowing seamless migrations from PostgreSQL or Debezium-based systems without re-architecting downstream services. Whether you're working with real-time analytics, event-driven systems, or audit logs, the enriched format provides clear context about each change event, including source information, schema, operation type, and timestamps. It simplifies debugging, enhances observability, and makes changefeeds more useful in complex, distributed architectures. | 25.2 |  |  |  |

#### Observability

Feature | Availability
--- | ---
Ver. | Self-hosted | Advanced | Standard | Basic
Additional logs and metrics to identify and detect hotspots Range logs are now emitted to the `OPS` channel. In 25.2.1, Range logs will be emitted to the `HEALTH` channel, In 25.2.2, additional logs and metrics will be available to help you detect performance hotspots. During high CPU load, range logs will be emitted more frequently, with added fields that highlight potential hot row and index scenarios | 25.2 |  |  |  |
Configure DB Console to display timestamps in any time zone Using a new cluster setting, you can now configure DB Console to display timestamps in any time zone. If the former cluster setting was set, its value is applied to the new setting when you upgrade to v25.2. For details, refer to DB Console Timezone Configuration). | 25.2 |  |  |  |
Multi-dimensional metrics In v25.2.1, multi-dimensional metrics by application name and database name will be available in Preview, enabling you to segment and track critical SQL metrics by database or application. | 25.2 |  |  |  |

#### Security

Feature | Availability
--- | ---
Ver. | Self-hosted | Advanced | Standard | Basic
Configurable TLS cipher suite restrictions A new `cockroach start` flag, `--tls-cipher-suites`, allows administrators to restrict which supported TLS cipher suites are permitted for incoming SQL, RPC, and HTTP connections. Connections using disallowed cipher suites are rejected and logged. The restriction applies to both TLS 1.2 and TLS 1.3, enabling tighter control over cryptographic standards in secure clusters. | 25.2 |  |  |  |
Row-Level Security Controlling who can access what data is more important than ever as organizations scale and modernize their data infrastructure. As enterprises move to modernize their critical databases, they need fine-grained, built-in access controls that go beyond table-level permissions. That’s why, with the 25.2 release of CockroachDB, we’re introducing Row-Level Security — a powerful feature that allows you to define and enforce access policies at the row level, directly within the database. This form of mandatory access control enables developers and operators to tightly govern data visibility based on user roles or attributes — making it a natural fit for securing sensitive workloads and building robust multi-tenant applications. With row-level security, CockroachDB makes it simple to isolate data, comply with regulatory requirements, and reduce application-side complexity — all while maintaining performance at scale and with minimal application changes. | 25.2 |  |  |  |

#### SQL

Feature | Availability
--- | ---
Ver. | Self-hosted | Advanced | Standard | Basic
Faster index creation on large tables Schema change operations such as index creations are now up to 30% faster based on our testing with a sample workload on a 1TB table. | 25.2 |  |  |  |
Vector indexing available in Preview CockroachDB now offers vector indexing in preview, enabling efficient storage and similarity search over high-dimensional data. This feature simplifies building recommendation engines, semantic search, and other machine-learning workflows directly in the database—letting you prototype and integrate advanced vector-based applications without external tooling while taking advantage of powerful SQL semantics. | 25.2 |  |  |  |
JSONPath support in Preview Preview support for JSONPath enables powerful, declarative querying and manipulation of deeply nested JSON structures. This makes it easier to work with complex JSON data and prototype advanced JSON-based workflows. | 25.2 |  |  |  |

#### Licensing

Feature | Availability
--- | ---
Ver. | Self-hosted | Advanced | Standard | Basic
Manage Enterprise license keys in the Cloud Console You can now manage new Enterprise license keys for self-hosted CockroachDB clusters in the CockroachDB Cloud Console. This feature can help you keep better track of your license keys, their expiration dates, and important notifications. | All* |  |  |  |

Feature detail key
★ | Features marked "All*" were recently made available in the CockroachDB Cloud platform. They are available for all supported versions of CockroachDB, under the deployment methods specified in their row under Availability.
★★ | Features marked "All**" were recently made available via tools maintained outside of the CockroachDB binary. They are available to use with all supported versions of CockroachDB, under the deployment methods specified in their row under Availability.
| Feature is available for this deployment method of CockroachDB as specified in the icon’s column: CockroachDB Self-hosted, CockroachDB Advanced, CockroachDB Standard, or CockroachDB Basic.
| Feature is not available for this deployment method of CockroachDB as specified in the icon’s column: CockroachDB Self-hosted, CockroachDB Advanced, CockroachDB Standard, or CockroachDB Basic.

#### Backward-incompatible changes

Before upgrading to CockroachDB v25.2, be sure to review the following backward-incompatible changes, as well as key cluster setting changes, and adjust your deployment as necessary.

- The default value of the `autocommit_before_ddl` session variable is now `true`. This will cause any schema change statement that is sent during a transaction to make the current transaction commit before executing the schema change in a separate transaction. Users who do not want the autocommit behavior can preserve the previous behavior by changing the default value of `autocommit_before_ddl` with: `ALTER ROLE ALL SET autocommit_before_ddl = false;`. #139871
- `DROP INDEX` can now only be run when `sql_safe_updates` is set to `false`. #139456
- Vector indexes do not support mutation while being created with `CREATE INDEX` or rebuilt with `ALTER PRIMARY KEY`. To prevent inadvertent application downtime, set the `sql_safe_updates` session setting to `false` when using `CREATE INDEX` or `ALTER PRIMARY KEY` with a vector index. #144601
- The variable arguments of polymorphic built-in functions (e.g., `concat`, `num_nulls`, `format`, `concat_ws`, etc.) no longer need to have the same type, matching PostgreSQL behavior. As a result, CockroachDB's type inference engine will no longer be able to infer argument types in some cases where it previously could, and there is a possibility that CockroachDB applications will encounter new errors. The new session variable `use_pre_25_2_variadic_builtins` restores the previous behavior (and limitations). #144600

#### Features that require upgrade finalization

During a major-version upgrade, certain features and performance improvements may not be available until the upgrade is finalized. In v25.2, these are:

- Row-level security
- Creating a set-returning PL/pgSQL function
- Support for the `jsonpath` data type

#### Key cluster setting changes

Changes to cluster settings should be reviewed prior to upgrading. New default cluster setting values will be used unless you have manually set a value for a setting. This can be confirmed by running the SQL statement `SELECT * FROM system.settings` to view the non-default settings.

##### Settings added

- `feature.vector_index.enabled` - Set to `TRUE` to enable vector indexes. Default is `FALSE` (not enabled).
- `server.child_metrics.include_aggregate.enabled` - When `TRUE`, reports both aggregate and child Prometheus metrics, which can be helpful for quick top-level insights or backward compatibility, but should be disabled if you’re seeing inflated values in Prometheus queries due to double counting. Defaults to `TRUE`.
- `ui.default_timezone` - Allows you to set the time zone for displayed timestamps in the DB Console. (Refer to DB Console timezone configuration.) Replaces the deprecated `ui.display_timezone` cluster setting. If that value had been set, it will automatically be applied to the new setting `ui.default_timezone`, which takes precedence.
- `server.oidc_authentication.provider.custom_ca` - Supports a custom root CA for verifying certificates while authenticating with an OIDC provider.
- `sql.stats.automatic_full_collection.enabled` - It is now possible to automatically collect partial table statistics, but disable automatic collection of full table statistics. To do so, change this setting to `FALSE`. It defaults to `TRUE`. In addition to this cluster setting, you can use the table setting `sql_stats_automatic_full_collection_enabled`.

##### Settings with changed visibility

The following settings are now marked `public` after previously being `reserved`. Reserved settings are not documented and their tuning by customers is not supported.

- `sql.stats.detailed_latency_metrics.enabled` - Percentile latencies are no longer available for SQL Activity. The implementation of these percentiles was error-prone and difficult to understand because it was computed differently from the other SQL statistics collected. Customers interested in viewing percentile latencies per statement fingerprint are encouraged to use the experimental per-fingerprint histograms that can be enabled with the `sql.stats.detailed_latency_metrics.enabled` cluster setting. This will enable externalized histogram metrics via the Prometheus scrape endpoint. #139500

##### Settings requiring operational changes

- To prevent unnecessary queuing in admission control CPU queues, set the `goschedstats.always_use_short_sample_period.enabled` cluster setting to `true` for any production cluster.

#### Deprecations

The following deprecations are announced in v25.2.

- The `ui.display_timezone` cluster setting is now deprecated and will be removed in a future release. If it has been set, its value will automatically be applied to the new setting `ui.default_timezone`, which takes precedence. For further detail, refer to DB Console timezone configuration.
- The `EXPERIMENTAL CHANGEFEED FOR` SQL statement is now deprecated and will be removed in a future release. Instead, create a sinkless changefeed that emits messages directly to a SQL client with the `CREATE CHANGEFEED` statement.

#### Known limitations

For information about new and unresolved limitations in CockroachDB v25.2, with suggested workarounds where applicable, refer to Known Limitations.

#### Additional resources

Resource | Topic | Description
--- | --- | ---
Cockroach University | Introduction to Distributed SQL and CockroachDB | This course introduces the core concepts behind distributed SQL databases and describes how CockroachDB fits into this landscape. You will learn what differentiates CockroachDB from both legacy SQL and NoSQL databases and how CockroachDB ensures consistent transactions without sacrificing scale and resiliency. You'll learn about CockroachDB's seamless horizontal scalability, distributed transactions with strict ACID guarantees, and high availability and resilience.
Cockroach University | Practical First Steps with CockroachDB | This course will give you the tools you need to get started with CockroachDB. During the course, you will learn how to spin up a cluster, use the Admin UI to monitor cluster activity, and use SQL shell to solve a set of hands-on exercises.
Cockroach University | Enterprise Application Development with CockroachDB | This course is the first in a series designed to equip you with best practices for mastering application-level (client-side) transaction management in CockroachDB. We'll dive deep on common differences between CockroachDB and legacy SQL databases and help you sidestep challenges you might encounter when migrating to CockroachDB from Oracle, PostgreSQL, and MySQL.
Cockroach University | Building a Highly Resilient Multi-region Database using CockroachDB | This course is part of a series introducing solutions to running low-latency, highly resilient applications for data-intensive workloads on CockroachDB. In this course we focus on surviving large-scale infrastructure failures like losing an entire cloud region without losing data during recovery. We'll show you how to use CockroachDB survival goals in a multi-region cluster to implement a highly resilient database that survives node or network failures across multiple regions with zero data loss.
Docs | Migration Overview | This page summarizes the steps of migrating a database to CockroachDB, which include testing and updating your schema to work with CockroachDB, moving your data into CockroachDB, and testing and updating your application.
Docs | Architecture Overview | This page provides a starting point for understanding the architecture and design choices that enable CockroachDB's scalability and consistency capabilities.
Docs | SQL Feature Support | The page summarizes the standard SQL features CockroachDB supports as well as common extensions to the standard.
Docs | Change Data Capture Overview | This page summarizes CockroachDB's data streaming capabilities. Change data capture (CDC) provides efficient, distributed, row-level changefeeds into a configurable sink for downstream processing such as reporting, caching, or full-text indexing.
Docs | Backup Architecture | This page describes the backup job workflow with a high-level overview, diagrams, and more details on each phase of the job.

## v25.2.0-rc.1

Release Date: May 12, 2025

### Downloads

Warning:

CockroachDB v25.2.0-rc.1 is a testing release. Testing releases are intended for testing and experimentation only, and are not qualified for production environments and not eligible for support or uptime SLA commitments.

Note:

Experimental downloads are not qualified for production use and not eligible for support or uptime SLA commitments, whether they are for testing releases or production releases.

Operating System | Architecture | Full executable | SQL-only executable
--- | --- | --- | ---
Linux | Intel | cockroach-v25.2.0-rc.1.linux-amd64.tgz (SHA256) | cockroach-sql-v25.2.0-rc.1.linux-amd64.tgz (SHA256)
ARM | cockroach-v25.2.0-rc.1.linux-arm64.tgz (SHA256) | cockroach-sql-v25.2.0-rc.1.linux-arm64.tgz (SHA256)
Mac (Experimental) | Intel | cockroach-v25.2.0-rc.1.darwin-10.9-amd64.tgz (SHA256) | cockroach-sql-v25.2.0-rc.1.darwin-10.9-amd64.tgz (SHA256)
ARM | cockroach-v25.2.0-rc.1.darwin-11.0-arm64.tgz (SHA256) | cockroach-sql-v25.2.0-rc.1.darwin-11.0-arm64.tgz (SHA256)
Windows (Experimental) | Intel | cockroach-v25.2.0-rc.1.windows-6.2-amd64.zip (SHA256) | cockroach-sql-v25.2.0-rc.1.windows-6.2-amd64.zip (SHA256)

### Docker image

Multi-platform images include support for both Intel and ARM. Multi-platform images do not take up additional space on your Docker host.

Within the multi-platform image, both Intel and ARM images are generally available for production use.

To download the Docker image:

    docker pull cockroachdb/cockroach-unstable:v25.2.0-rc.1

### Source tag

To view or download the source code for CockroachDB v25.2.0-rc.1 on Github, visit v25.2.0-rc.1 source tag.

### Changelog

View a detailed changelog on GitHub: v25.2.0-beta.3...v25.2.0-rc.1

### SQL language changes

- Non-integer array indices are now supported in JSONPath queries (e.g., `SELECT jsonb_path_query('[1, 2, 3]', '$[2.5]');`). Indices are rounded toward 0. #144819
- The `vector_l2_ops` operator class can now be specified for a vector index. Because `vector_l2_ops` is the default, it is possible to omit the operator class from an index definition. #144902
- When creating a vector index with the `USING` syntax, `hnsw` can now be specified as the index type, although a `cspann` vector index is still provided. This change increases compatibility with third-party tools. #144902
- Added support for numeric JSONPath methods `.abs()`, `.floor()`, `.ceiling()`. For example, `SELECT jsonb_path_query('-0.5', '$.abs()');`. #145121
- Disabled `IMPORT INTO` for tables with vector indexes, because importing into vector indexes is not implemented. #145262
- Added support for `like_regex` flags in JSONPath queries. For example, `SELECT jsonb_path_query('{}', '"a" like_regex ".*" flag "i"');`. #145300
- Vector index creation is now prevented until the entire cluster upgrade has been finalized on v25.2 or later. #145449

### Bug fixes

- `NULL` vectors can now be inserted into tables with vector indexes. #144858
- Fixed a bug that caused vector indexes to return incorrect or no results from a standby reader in a physical cluster replication (PCR) setup. This bug existed in alpha versions of v25.2 and in v25.2.0-beta.1. #145157
- Fixed a bug that allowed a set-returning PL/pgSQL function to be created before the version change was finalized. This bug existed in v25.2 alpha and beta releases. #145381
- Fixed a bug where CockroachDB could encounter an internal error when fetching from the `WITH HOLD` cursor with `FETCH FIRST` and `FETCH ABSOLUTE`. The bug was only present in v25.2 alpha and beta releases. #145409

### Performance improvements

- Some internal queries executed by the jobs system are now less likely to perform full table scans of the `system.jobs` table, making them more efficient. This change can be reverted by disabling the `jobs.avoid_full_scans_in_find_running_jobs.enabled` cluster setting. #144825

### Miscellaneous

- SQL queries run on the source cluster by logical data replication (LDR) and physical cluster replication (PCR) will account to internal metrics like `sql.statements.active.internal` instead of the metrics like `sql.statements.active` that are used to monitor application workload. #145111

## v25.2.0-beta.3

Release Date: April 28, 2025

### Downloads

Warning:

CockroachDB v25.2.0-beta.3 is a testing release. Testing releases are intended for testing and experimentation only, and are not qualified for production environments and not eligible for support or uptime SLA commitments.

Note:

Experimental downloads are not qualified for production use and not eligible for support or uptime SLA commitments, whether they are for testing releases or production releases.

Operating System | Architecture | Full executable | SQL-only executable
--- | --- | --- | ---
Linux | Intel | cockroach-v25.2.0-beta.3.linux-amd64.tgz (SHA256) | cockroach-sql-v25.2.0-beta.3.linux-amd64.tgz (SHA256)
ARM | cockroach-v25.2.0-beta.3.linux-arm64.tgz (SHA256) | cockroach-sql-v25.2.0-beta.3.linux-arm64.tgz (SHA256)
Mac (Experimental) | Intel | cockroach-v25.2.0-beta.3.darwin-10.9-amd64.tgz (SHA256) | cockroach-sql-v25.2.0-beta.3.darwin-10.9-amd64.tgz (SHA256)
ARM | cockroach-v25.2.0-beta.3.darwin-11.0-arm64.tgz (SHA256) | cockroach-sql-v25.2.0-beta.3.darwin-11.0-arm64.tgz (SHA256)
Windows (Experimental) | Intel | cockroach-v25.2.0-beta.3.windows-6.2-amd64.zip (SHA256) | cockroach-sql-v25.2.0-beta.3.windows-6.2-amd64.zip (SHA256)

### Docker image

Multi-platform images include support for both Intel and ARM. Multi-platform images do not take up additional space on your Docker host.

Within the multi-platform image, both Intel and ARM images are generally available for production use.

To download the Docker image:

    docker pull cockroachdb/cockroach-unstable:v25.2.0-beta.3

### Source tag

To view or download the source code for CockroachDB v25.2.0-beta.3 on Github, visit v25.2.0-beta.3 source tag.

### Changelog

View a detailed changelog on GitHub: v25.2.0-beta.2...v25.2.0-beta.3

### SQL language changes

- `CREATE VECTOR INDEX` and `ALTER PRIMARY KEY` now send a notice that vector indexes will be offline during the change operation when the `sql_safe_updates` session setting is disabled. #144601
- Vector indexes do not support mutation while being created with `CREATE INDEX` or rebuilt with `ALTER PRIMARY KEY`. To prevent inadvertent application downtime, set the `sql_safe_updates` session setting to `false` when using `CREATE INDEX` or `ALTER PRIMARY KEY` with a vector index. #144601
- The variable arguments of polymorphic built-in functions (e.g., `concat`, `num_nulls`, `format`, `concat_ws`, etc.) no longer need to have the same type, matching PostgreSQL behavior. As a result, CockroachDB's type inference engine will no longer be able to infer argument types in some cases where it previously could, and there is a possibility that CockroachDB applications will encounter new errors. The new session variable `use_pre_25_2_variadic_builtins` restores the previous behavior (and limitations). #144600

### Bug fixes

- Fixed a bug that could cause a changefeed to complete erroneously when one of its watched tables encounters a schema change. #144717
- Fixed a bug in the DB Console where tables with page size dropdowns failed to update when a new page size option was selected. Tables now update correctly. #144666
- Fixed the following bugs in the Schedules page of the DB Console:
  - Where the Schedules page displayed only a subset of a cluster's schedules. The Schedules page now correctly displays all schedules.
  - Where manually updating the `show` or `status` parameters in the URL (e.g., `http://127.0.0.1:8080/#/schedules?status=ACTIVE&show=50`) caused the Schedules page to fail to load. #144807
- Fixed a bug in the SQL Activity Statements page where filtering by Statement Type returned no results. The filter now works as expected. #144851
- Fixed a bug in the DB Console where the Drop unused index tag appeared multiple times for an index on the Indexes tab of the Table Details page. #144656

### Performance improvements

- Triggers now perform the descriptor lookup for `TG_TABLE_SCHEMA` against a cache. This can significantly reduce trigger planning latency in multi-region databases. #144521
- The vector search optimizer rule now supports additional projections beyond the distance column, including the implicit projections added for virtual columns. #144583

## v25.2.0-beta.2

Release Date: April 23, 2025

### Downloads

Warning:

CockroachDB v25.2.0-beta.2 is a testing release. Testing releases are intended for testing and experimentation only, and are not qualified for production environments and not eligible for support or uptime SLA commitments.

Note:

Experimental downloads are not qualified for production use and not eligible for support or uptime SLA commitments, whether they are for testing releases or production releases.

Operating System | Architecture | Full executable | SQL-only executable
--- | --- | --- | ---
Linux | Intel | cockroach-v25.2.0-beta.2.linux-amd64.tgz (SHA256) | cockroach-sql-v25.2.0-beta.2.linux-amd64.tgz (SHA256)
ARM | cockroach-v25.2.0-beta.2.linux-arm64.tgz (SHA256) | cockroach-sql-v25.2.0-beta.2.linux-arm64.tgz (SHA256)
Mac (Experimental) | Intel | cockroach-v25.2.0-beta.2.darwin-10.9-amd64.tgz (SHA256) | cockroach-sql-v25.2.0-beta.2.darwin-10.9-amd64.tgz (SHA256)
ARM | cockroach-v25.2.0-beta.2.darwin-11.0-arm64.tgz (SHA256) | cockroach-sql-v25.2.0-beta.2.darwin-11.0-arm64.tgz (SHA256)
Windows (Experimental) | Intel | cockroach-v25.2.0-beta.2.windows-6.2-amd64.zip (SHA256) | cockroach-sql-v25.2.0-beta.2.windows-6.2-amd64.zip (SHA256)

### Docker image

Multi-platform images include support for both Intel and ARM. Multi-platform images do not take up additional space on your Docker host.

Within the multi-platform image, both Intel and ARM images are generally available for production use.

To download the Docker image:

    docker pull cockroachdb/cockroach-unstable:v25.2.0-beta.2

### Source tag

To view or download the source code for CockroachDB v25.2.0-beta.2 on Github, visit v25.2.0-beta.2 source tag.

### Changelog

View a detailed changelog on GitHub: v25.2.0-beta.1...v25.2.0-beta.2

### SQL language changes

- Added the `jsonb_path_match` function, which returns the result of a predicate query. #144271
- The `.type()` method is now supported in JSONPath queries. For example, `SELECT jsonb_path_query('[1, 2, 3]', '$.type()');`. #144405
- Removed the `ST_3DLength` function. #144549
- Added the `jsonb_path_query_first` function, which returns the first result from `jsonb_path_query`. #144271
- Parenthesized expressions are now supported in JSONPath queries. For example, `SELECT jsonb_path_query('{"a": {"b": true}}', '($.a).b');` #144298
- The `.size()` method is now supported in JSONPath expressions. For example, `SELECT jsonb_path_query('[1, 2, 3]', '$.size()');`. #144405
- Added the `jsonb_path_query_array` function, which returns the result of `jsonb_path_query` wrapped in a JSON array. #144271

### Operational changes

- Logical data replication (LDR) now supports partial indexes by default. #144513

### Miscellaneous

- Fixed a rare corruption bug that could affect `IMPORT`, physical cluster replication (PCR), `CREATE TABLE AS` (CTAS), and materialized view refreshes. #144663
- Vector indexes created in v25.2.0-beta.1 are not compatible with later releases. Drop and re-create these indexes before using them with later releases. #144581

## v25.2.0-beta.1

Release Date: April 14, 2025

### Downloads

Warning:

CockroachDB v25.2.0-beta.1 is a testing release. Testing releases are intended for testing and experimentation only, and are not qualified for production environments and not eligible for support or uptime SLA commitments.

Note:

Experimental downloads are not qualified for production use and not eligible for support or uptime SLA commitments, whether they are for testing releases or production releases.

Operating System | Architecture | Full executable | SQL-only executable
--- | --- | --- | ---
Linux | Intel | cockroach-v25.2.0-beta.1.linux-amd64.tgz (SHA256) | cockroach-sql-v25.2.0-beta.1.linux-amd64.tgz (SHA256)
ARM | cockroach-v25.2.0-beta.1.linux-arm64.tgz (SHA256) | cockroach-sql-v25.2.0-beta.1.linux-arm64.tgz (SHA256)
Mac (Experimental) | Intel | cockroach-v25.2.0-beta.1.darwin-10.9-amd64.tgz (SHA256) | cockroach-sql-v25.2.0-beta.1.darwin-10.9-amd64.tgz (SHA256)
ARM | cockroach-v25.2.0-beta.1.darwin-11.0-arm64.tgz (SHA256) | cockroach-sql-v25.2.0-beta.1.darwin-11.0-arm64.tgz (SHA256)
Windows (Experimental) | Intel | cockroach-v25.2.0-beta.1.windows-6.2-amd64.zip (SHA256) | cockroach-sql-v25.2.0-beta.1.windows-6.2-amd64.zip (SHA256)

### Docker image

Multi-platform images include support for both Intel and ARM. Multi-platform images do not take up additional space on your Docker host.

Within the multi-platform image, both Intel and ARM images are generally available for production use.

To download the Docker image:

    docker pull cockroachdb/cockroach-unstable:v25.2.0-beta.1

### Source tag

To view or download the source code for CockroachDB v25.2.0-beta.1 on Github, visit v25.2.0-beta.1 source tag.

### Changelog

View a detailed changelog on GitHub: v25.2.0-alpha.3...v25.2.0-beta.1

### SQL language changes

- Set-returning functions (SRF) are now supported in PL/pgSQL. A PL/pgSQL SRF can be created by declaring the return type as `SETOF <type>` or `TABLE`. #143820
- Usage of `TG_ARGV` in trigger functions is now disallowed by default. The session setting `allow_create_trigger_function_with_argv_references` can be set to `true` to allow usage (with 1-based indexing). #143827
- The return type of the `workload_index_recs` built-in function now includes two columns. The first column, `index_rec`, remains a `STRING` type and contains the index recommendation. The second column, `fingerprint_ids`, is new and has the `BYTES[]` type. #142927
- The job description for `AUTO CREATE PARTIAL STATS` now clearly indicates that the job is for automatic partial statistics collection, improving `system.jobs` visibility and debugging. #143283
- A new `execution time` statistic is now reported on `EXPLAIN ANALYZE` output for most operators. Previously, this statistic was only available on the DistSQL diagrams in `EXPLAIN ANALYZE (DISTSQL)` output. #143857
- `() is unknown` is now supported in JSONPath queries. For example, `SELECT jsonb_path_query('{}', '($ < 1) is unknown');`. #143668
- `starts with ""` is now supported in JSONPath queries. For example, `SELECT jsonb_path_query('"abcdef"', '$ starts with "abc"');`. #143675

### Operational changes

- The `kv.mvcc_gc.queue_kv_admission_control.enabled` cluster setting was retired. #143124
- `debug zip` queries are now attributed to internal SQL metrics. As a result, users will no longer see their impact on the SQL charts in the DB Console. #143711

### Bug fixes

- Fixed an issue where hot range logging for virtual clusters omitted some hot ranges. #143775
- MVCC garbage collection is now fully subject to IO admission control. Previously, it was possible for MVCC GC to cause store overload (such as LSM inversion) when a large amount of data would become eligible for garbage collection. Should any issues arise from subjecting MVCC GC to admission control, the `kv.mvcc_gc.queue_kv_admission_control.enabled` cluster setting can be set to `false` to restore the previous behavior. #143122
- Fixed a bug that could cause a stack overflow during execution of a prepared statement that invoked a PL/pgSQL routine with a loop. The bug existed in versions v23.2.22, v24.1.15, v24.3.9, v25.1.2, v25.1.3, and pre-release versions of v25.2 prior to v25.2.0-alpha.3. #144027
- Fixed an issue where change data capture queries on tables without columns would fail with an internal error: `unable to determine result columns`. #142068
- Previously, statement bundle collection could encounter `not enough privileges` errors when retrieving necessary information (e.g., cluster settings, table statistics, etc.) when the user that requested the bundle was different from the user that actually ran the query. This is now fixed. The bug was present since v20.2 and would result in partially incomplete bundles. #144178
- Fixed an issue where databases, tables, and indexes were not appearing on the Hot Ranges page for application virtual clusters. #143441

## v25.2.0-alpha.3

Release Date: April 7, 2025

### Downloads

Warning:

CockroachDB v25.2.0-alpha.3 is a testing release. Testing releases are intended for testing and experimentation only, and are not qualified for production environments and not eligible for support or uptime SLA commitments.

Note:

Experimental downloads are not qualified for production use and not eligible for support or uptime SLA commitments, whether they are for testing releases or production releases.

Operating System | Architecture | Full executable | SQL-only executable
--- | --- | --- | ---
Linux | Intel | cockroach-v25.2.0-alpha.3.linux-amd64.tgz (SHA256) | cockroach-sql-v25.2.0-alpha.3.linux-amd64.tgz (SHA256)
ARM | cockroach-v25.2.0-alpha.3.linux-arm64.tgz (SHA256) | cockroach-sql-v25.2.0-alpha.3.linux-arm64.tgz (SHA256)
Mac (Experimental) | Intel | cockroach-v25.2.0-alpha.3.darwin-10.9-amd64.tgz (SHA256) | cockroach-sql-v25.2.0-alpha.3.darwin-10.9-amd64.tgz (SHA256)
ARM | cockroach-v25.2.0-alpha.3.darwin-11.0-arm64.tgz (SHA256) | cockroach-sql-v25.2.0-alpha.3.darwin-11.0-arm64.tgz (SHA256)
Windows (Experimental) | Intel | cockroach-v25.2.0-alpha.3.windows-6.2-amd64.zip (SHA256) | cockroach-sql-v25.2.0-alpha.3.windows-6.2-amd64.zip (SHA256)

### Docker image

Multi-platform images include support for both Intel and ARM. Multi-platform images do not take up additional space on your Docker host.

Within the multi-platform image, both Intel and ARM images are generally available for production use.

To download the Docker image:

    docker pull cockroachdb/cockroach-unstable:v25.2.0-alpha.3

### Source tag

To view or download the source code for CockroachDB v25.2.0-alpha.3 on Github, visit v25.2.0-alpha.3 source tag.

### Changelog

View a detailed changelog on GitHub: v25.2.0-alpha.2...v25.2.0-alpha.3

### SQL language changes

- `last` is now supported for array indexing in JSONPath queries. For example, `SELECT jsonb_path_query('[1, 2, 3, 4]', '$[1 to last]');`. #143658
- String comparisons are now supported in JSONPath queries. For example, `SELECT jsonb_path_query('{}', '"a" < "b"');`. #143240
- Added the `ST_3DLength` function, which returns the 3D or 2D length of `LINESTRING` and `MULTILINESTRING` spatial types. #139450
- Updated edge cases in the `width_bucket()` function to return `count + 1` for a positive infinity operand, and `0` for a negative infinity operand, instead of an error. #142932
- Unary arithmetic operators are now supported in JSONPath queries. For example, `SELECT jsonb_path_query('[1, 2, 3]', '-$');`. #143613
- Implemented various `power()` and `^` edge cases to match PostgreSQL behaviour. Some expressions that previously returned `NaN` now return specific numbers; some expressions that previously returned `Infinity` or `NaN` now return errors; and some expressions with infinite exponents now return different results. #142932
- Null comparisons are now supported in JSONPath queries. For example, `SELECT jsonb_path_query('{}', 'null != 1');`. #143240
- Wildcard key accessors are now supported in JSONPath queries. For example, `SELECT jsonb_path_query('{"a": 1, "b": true}', '$.*');`. #143588
- `like_regex` predicate evaluation is now supported in JSONPath queries. For example, `SELECT jsonb_path_query('{}', '"hello" like_regex "^he.*$"');`. #143240

### Operational changes

- The `server.client_cert_expiration_cache.capacity` cluster setting has been removed. The `security.certificate.expiration.client` and `security.certificate.ttl.client` metrics now report the lowest value observed for a user in the last 24 hours. #143384
- Previously, the user provided in the source URI in the logical data replication (LDR) stream required the `REPLICATIONSOURCE` privilege at the system level. With this change, the user only needs this privilege on the source tables (i.e., a table-level privilege). #143456

### DB Console changes

- The lock and latch wait time components of a query's cumulative contention time are now tracked separately and surfaced as annotations in `EXPLAIN ANALYZE` output. #113649
- The metric that measures cumulative contention time now includes time spent waiting to acquire latches, in addition to time spent acquiring locks. This metric is displayed in both the DB Console and the `EXPLAIN ANALYZE` output. #113649

### Bug fixes

- Fixed a bug where index backfills unnecessarily merged new data written to an index, which could lead to extra contention. #142768
- Column IDs are now validated when starting an `immediate` mode logical data replication stream. #143773
- Fixed a bug where a GC threshold error (which appears as "batch timestamp must be after replica GC threshold ...") could cause a schema change that backfills data to fail. Now, the error will cause the backfill to be retried at a higher timestamp to avoid the error. #143451
- Fixed a bug where index backfill progress before a `PAUSE`/`RESUME` would not get tracked. #142602
- Fixed a bug that could cause a function reference to be left behind if a procedure referred to another procedure that depended on a a table, and that table was dropped with `CASCADE`. #143538
- Fixed a potential deadlock that could occur during client certificate updates while metrics were being collected. This issue affected the reliability of certificate expiration reporting. #143663
- Previously, the fields `maximum memory usage` and `max sql temp disk usage` in the `EXPLAIN ANALYZE` output could be under-reported for distributed plans when memory-intensive operations were fully performed on the remote nodes. This is now fixed. The bug existed in v22.1 and later. #143777
- The `ALTER VIRTUAL CLUSTER SET REPLICATION READ VIRTUAL CLUSTER` syntax is now supported for adding a reader virtual cluster for an existing physical cluster replication (PCR) standby cluster. #143752

### Performance improvements

- Schema changes that require data to be backfilled no longer hold a protected timestamp for the entire duration of the backfill, which means there is less overhead caused by MVCC garbage collection after the backfill completes. #143451
- Fixed a bug that caused the optimizer to over-estimate the cost of inverted index scans in some cases. Now, plans with inverted index scans should be selected in more cases where they are optimal. #120079

## v25.2.0-alpha.2

Release Date: March 31, 2025

### Downloads

Warning:

CockroachDB v25.2.0-alpha.2 is a testing release. Testing releases are intended for testing and experimentation only, and are not qualified for production environments and not eligible for support or uptime SLA commitments.

Note:

Experimental downloads are not qualified for production use and not eligible for support or uptime SLA commitments, whether they are for testing releases or production releases.

Operating System | Architecture | Full executable | SQL-only executable
--- | --- | --- | ---
Linux | Intel | cockroach-v25.2.0-alpha.2.linux-amd64.tgz (SHA256) | cockroach-sql-v25.2.0-alpha.2.linux-amd64.tgz (SHA256)
ARM | cockroach-v25.2.0-alpha.2.linux-arm64.tgz (SHA256) | cockroach-sql-v25.2.0-alpha.2.linux-arm64.tgz (SHA256)
Mac (Experimental) | Intel | cockroach-v25.2.0-alpha.2.darwin-10.9-amd64.tgz (SHA256) | cockroach-sql-v25.2.0-alpha.2.darwin-10.9-amd64.tgz (SHA256)
ARM | cockroach-v25.2.0-alpha.2.darwin-11.0-arm64.tgz (SHA256) | cockroach-sql-v25.2.0-alpha.2.darwin-11.0-arm64.tgz (SHA256)
Windows (Experimental) | Intel | cockroach-v25.2.0-alpha.2.windows-6.2-amd64.zip (SHA256) | cockroach-sql-v25.2.0-alpha.2.windows-6.2-amd64.zip (SHA256)

### Docker image

Multi-platform images include support for both Intel and ARM. Multi-platform images do not take up additional space on your Docker host.

Within the multi-platform image, both Intel and ARM images are generally available for production use.

To download the Docker image:

    docker pull cockroachdb/cockroach-unstable:v25.2.0-alpha.2

### Source tag

To view or download the source code for CockroachDB v25.2.0-alpha.2 on Github, visit v25.2.0-alpha.2 source tag.

### Changelog

View a detailed changelog on GitHub: v25.2.0-alpha.1...v25.2.0-alpha.2

### SQL language changes

- `num_nulls()` and `num_nonnulls()` no longer require that all arguments have the same type. #141193
- `concat()` no longer requires that all arguments have the same type. #141193
- `pg_column_size()` no longer requires that all arguments have the same type. #141193
- Users can now begin logical data replication (LDR) on an existing table if the user has a table-level `REPLICATIONDEST` privilege. Furthermore, users can now begin LDR onto an automatically created table if the user has the parent database level `CREATE` privilege. Finally, during bidirectional LDR, the user in the original source URI, who will begin the reverse LDR stream, will authorize via this table-level `REPLICATIONDEST` privilege. #142840
- `concat_ws()` now accepts arguments of any type in the second and later positions (the separator must still be a string). #141193
- Filters are now supported in JSONPath queries, using the format `$ ? (predicate)`. This allows results to be filtered. For example, `SELECT jsonb_path_query('{"a": [1,2,3]}', '$.a ? (1 == 1)');`. #143097
- `format()` no longer requires that all post-format string arguments have the same type. #141193
- `json_build_object()`, `jsonb_build_object()`, `json_build_array()`, and `jsonb_build_array()` no longer require that all arguments have the same type. #141193
- Added the `jsonb_path_exists` function, which accepts a JSON object and JSONPath query and returns whether the query returned any items. #143028
- Addition, subtraction, multiplication, division, and modulo operators are now supported in JSONPath queries. #143210

### Operational changes

- All `ALTER VIRTUAL CLUSTER REPLICATION JOB` commands for physical cluster replication (PCR), except for `ALTER VIRTUAL CLUSTER SET REPLICATION SOURCE`, will require the `REPLICATIONDEST` privilege, in addition to `MANAGEVIRTUALCLUSTER`. `ALTER VIRTUAL CLUSTER SET REPLICATION SOURCE` now requires the `REPLICATIONSOURCE` privilege. If the ingestion job was created before v25.1, the user can still alter the replication job without the `REPLICATIONDEST` privilege. #142772

### DB Console changes

- The lock and latch wait time components of a query's cumulative contention time are now tracked separately and surfaced as annotations in `EXPLAIN ANALYZE` output. #113649
- The metric that measures cumulative contention time now includes time spent waiting to acquire latches, in addition to time spent acquiring locks. This metric is displayed in both the DB Console and the `EXPLAIN ANALYZE` output. #113649
- The Replica Quiescence graph on the Replication dashboard in the DB Console now displays the number of replicas quiesced with leader leases. #143215

### Bug fixes

- Fixed a bug where index backfills unnecessarily merged new data written to an index, which could lead to extra contention. #142768
- Fixed a bug that could leave behind a dangling reference to a dropped role if that role had default privileges granted to itself. The bug was caused by defining privileges such as: `ALTER DEFAULT PRIVILEGES FOR ROLE self_referencing_role GRANT INSERT ON TABLES TO self_referencing_role`. #143287
- Fixed a bug that caused changefeeds to fail on startup when scanning a single key. #143102
- Fixed a bug where secondary indexes could be unusable by DML statements while a primary key swap was occurring, if the new primary key did not contain columns from the old primary key. #141850
- Fixed a crash due to `use of enum metadata before hydration` when using LDR with user-defined types. #143311
- MVCC garbage collection is now fully subject to IO admission control. Previously, it was possible for MVCC GC to cause store overload (such as LSM inversion) when a large amounts of data would become eligible for garbage collection. Should any issues arise from subjecting MVCC GC to admission control, the `kv.mvcc_gc.queue_kv_admission_control.enabled` cluster setting can be set to `false` to restore the previous behavior. #143122
- Fixed a bug where CockroachDB would encounter an internal error when decoding the gists of plans with `CALL` statements. The bug had been present since v23.2. #143252
- Fixed a bug where calling a stored procedure could drop the procedure if it had `OUT` parameters that were not used by the calling routine. This bug had existed since PL/pgSQL `CALL` statements were introduced in v24.1. #143173
- Fixed a bug where CockroachDB incorrectly resolved routine overloads in some cases. Previously, it allowed creating routines with signatures differing only in type width (e.g., `f(p VARCHAR(1))` and `f(p VARCHAR(2))`), which is not permitted in PostgreSQL. This required precise type casting during invocation. Similarly, when dropping a routine, CockroachDB previously required exact types, unlike PostgreSQL, which is more lenient (e.g., `DROP FUNCTION f(VARCHAR)` would fail in the preceding example). This bug had existed since v23.1. #143159
- The reader virtual cluster now starts if the user begins a physical cluster replication (PCR) stream from a cursor via `ALTER VIRTUAL CLUSTER virtual_cluster START REPLICATION OF physical_cluster ON pgurl WITH READ VIRTUAL CLUSTER`. #143072

### Performance improvements

- Index backfills and row-level TTL deletions that encounter transaction contention will now be retried with smaller batch sizes more quickly, which reduces the latency of these jobs under high-contention workloads. #142702
- Queries that use `SHOW TABLES` without using the `estimated_row_count` column no longer need to look up the table statistics. #59838

### Miscellaneous

- `pg_column_size()` is now regarded as Stable, matching PostgreSQL. As a result, it will no longer be allowed in computed column expressions or partial index predicate expressions. #141193

## v25.2.0-alpha.1

Release Date: March 24, 2025

### Downloads

Warning:

CockroachDB v25.2.0-alpha.1 is a testing release. Testing releases are intended for testing and experimentation only, and are not qualified for production environments and not eligible for support or uptime SLA commitments.

Note:

Experimental downloads are not qualified for production use and not eligible for support or uptime SLA commitments, whether they are for testing releases or production releases.

Operating System | Architecture | Full executable | SQL-only executable
--- | --- | --- | ---
Linux | Intel | cockroach-v25.2.0-alpha.1.linux-amd64.tgz (SHA256) | cockroach-sql-v25.2.0-alpha.1.linux-amd64.tgz (SHA256)
ARM | cockroach-v25.2.0-alpha.1.linux-arm64.tgz (SHA256) | cockroach-sql-v25.2.0-alpha.1.linux-arm64.tgz (SHA256)
Mac (Experimental) | Intel | cockroach-v25.2.0-alpha.1.darwin-10.9-amd64.tgz (SHA256) | cockroach-sql-v25.2.0-alpha.1.darwin-10.9-amd64.tgz (SHA256)
ARM | cockroach-v25.2.0-alpha.1.darwin-11.0-arm64.tgz (SHA256) | cockroach-sql-v25.2.0-alpha.1.darwin-11.0-arm64.tgz (SHA256)
Windows (Experimental) | Intel | cockroach-v25.2.0-alpha.1.windows-6.2-amd64.zip (SHA256) | cockroach-sql-v25.2.0-alpha.1.windows-6.2-amd64.zip (SHA256)

### Docker image

Multi-platform images include support for both Intel and ARM. Multi-platform images do not take up additional space on your Docker host.

Within the multi-platform image, both Intel and ARM images are generally available for production use.

To download the Docker image:

    docker pull cockroachdb/cockroach-unstable:v25.2.0-alpha.1

### Source tag

To view or download the source code for CockroachDB v25.2.0-alpha.1 on Github, visit v25.2.0-alpha.1 source tag.

### Backward-incompatible changes

- The default value of the `autocommit_before_ddl` session variable is now `true`. This will cause any schema change statement that is sent during a transaction to make the current transaction commit before executing the schema change in a separate transaction. CockroachDB does not have full support for multiple schema changes in a transaction. Users who do not want the autocommit behavior can preserve the previous behavior by changing the default value of `autocommit_before_ddl` with: `ALTER ROLE ALL SET autocommit_before_ddl = false;`. #139871

### Security updates

- Added the `server.oidc_authentication.provider.custom_ca` cluster setting to support custom root CA for verifying certificates while authenticating with the OIDC provider. #140583

### General changes

- When changefeeds are created with a `resolved` option lower than the `min_checkpoint_frequency` option, an error message was displayed to inform the user. This message is now a notice and includes extra information if either option was set to its default value. #142094
- Added the logging of `changefeed_canceled` events to the telemetry log. #142139
- Updated the response headers of HTTP requests to include `"Cache-control: no-store"` instead of `"Cache-control:no-cache"`, which means that HTTP requests to the server will no longer be cached in the client. Requests for UI assets, such as `bundle.js` and fonts, will still include `"Cache-control:no-cache"` to ensure they are cached and that the DB console loads quickly. #142277
- Added the `headers_json_column_name` option to the Kafka sink, allowing users to specify a column in their table(s) of type `JSONB` to be used as the Kafka headers for each row. #142092
- Improved S3 credential caching for STS credentials. #142434

### SQL language changes

- The `plan_cache_mode` session setting now defaults to `auto`, enabling generic query plans for some queries. #135668
- `SHOW JOBS` is now based on a new mechanism for storing information about the progress and status of running jobs. #138104
- `SHOW VIRTUAL CLUSTER WITH REPLICATION STATUS` now displays the `ingestion_job_id` column after the `name` column. #138967
- Since v23.2 table statistics histograms have been collected for non-indexed JSON columns. Histograms are no longer collected for these columns. This reduces memory usage during table statistics collection, for both automatic and manual collection via `ANALYZE` and `CREATE STATISTICS`. This can be reverted by setting the cluster setting `sql.stats.non_indexed_json_histograms.enabled` to `true`. #139766
- `optimizer_use_merged_partial_statistics` is now enabled by default, meaning the optimizer will use partial stats if available to estimate more up-to-date statistics. #139925
- The `optimizer_prefer_bounded_cardinality` session setting has been added that instructs the optimizer to prefer query plans where every expression has a guaranteed upper-bound on the number of rows it will process. This may help the optimizer produce better query plans in some cases. This setting is disabled by default. #139985
- The `optimizer_min_row_count` session setting has been added that sets a lower bound on row count estimates for relational expressions during query planning. A value of `0`, which is the default, indicates no lower bound. If this is set to a value greater than `0`, a row count of `0` can still be estimated for expressions with a cardinality of `0`, e.g., for a contradictory filter. Setting this to a value higher than `0`, such as `1`, may yield better query plans in some cases, such as when statistics are frequently stale and inaccurate. #140065
- Fixed a bug existing only in pre-release versions of v25.1 that could cause unexpected errors during planning for `VALUES` expressions containing function calls with multiple overloads. #140277
- The `optimizer_check_input_min_row_count` session setting has been added to control the minimum row count estimate for buffer scans of foreign key and uniqueness checks. It defaults to `0`. #140735
- Added the `jsonpath` type, without parsing, evaluation, or table creation. Currently accepts any non-empty string. #140204
- Added the `substring_index` built-in function, which extracts a portion of a string based on a specified delimiter and occurrence count, which follows MySQL behavior. #141929
- Added compression support for changefeed webhook sinks. This reduces network bandwidth and storage usage, improving performance and lowering costs. Users can enable compression by setting the `compression=<algorithm>` option. Supported algorithms are `gzip` and `zstd`. #138872
- Holdable cursors declared using `CURSOR WITH HOLD` are now supported. A holdable cursor fully executes a query upon transaction commit and stores the result in a row container, which is maintained by the session. #141943
- The `split_part` built-in function now supports negative `return_index_pos` values, returning the |n|th field from the end when specified. #141944
- Added a parser for the `jsonpath` type. Accepts setting mode (`strict/lax`), key accessors (`.name`), and array wildcards (`[*]`). #142010
- Added the new option `WITH IGNORE_FOREIGN_KEYS` to the `SHOW CREATE TABLE` statement so that foreign key constraints are not included in the output schema. This option is also acceptable in `SHOW CREATE VIEW`, but has no influence there. It cannot be combined with the existing `WITH REDACT` option. #142151
- `CREATE TABLE AS SELECT ... FROM ... AS OF SYSTEM TIME x` is now supported. It cannot be executed within an explicit transaction. #142147
- Invocations of stored procedures via `CALL` statements will now be counted toward the newly added `sql.call_stored_proc.count.started` and `sql.call_stored_proc.count` metrics. Previously, they were counted against the `sql.misc.count.started` and `sql.misc.count` metrics. #142249
- Statements such as `REFRESH MATERIALIZED VIEW` and `CREATE MATERIALIZED VIEW` can now be executed with an `AS OF SYSTEM TIME` clause. These statements can still not be used in an explicit transaction. #142259
- Added support for the following in the `jsonpath` parser:
  - Double-quoted key accessors within `jsonpath` (`SELECT '$."1key"."key2"'::JSONPATH;`).
  - Array integer indexing (ex. `$.a[1]`).
  - Array ranges (ex. `$.a[1 to 3]`).
  - Array unions (ex `$.a[1, 2 to 4, 7, 8]`). #142241
- Fixed a regression due to join-elimination rules that left a Project operator below a `JOIN`, preventing optimizer rules from applying. #142252
- Added `ALTER VIRTUAL CLUSTER .. SET REPLICATION SOURCE` so users can configure the producer jobs on the source cluster for physical cluster replication (PCR). Currently, they can only configure the `EXPIRATION WINDOW`. This patch also removes the `EXPIRATION WINDOW` option from the consumer side of the statement, `ALTER VIRTUAL CLUSTER SET REPLICATION`. #142501
- Added the `jsonb_path_query` function, which takes in a JSON object and a `jsonpath` query, and returns the resulting JSON object. #142336
- Updated the `CREATE TRIGGER` statement `only implemented in the declarative schema changer` error message to include a helpful suggestion and link to relevant docs. #141738

### Operational changes

- Removed the `storage.queue.store-failures` metric. #139150
- Customers must provide URIs as external connections to create logical data replication (LDR) statements. #139383
- The following cluster settings have been deprecated:
  - `sql.metrics.statement_details.plan_collection.enabled`
  - `sql.metrics.statement_details.plan_collection.period` #138042
- Reduced noise when using dynamically provisioned logging sinks. #139565
- Added metrics for monitoring changefeed span-level checkpoint creation:
  - `changefeed.checkpoint.create_nanos`, which measures the time it takes to create a changefeed checkpoint.
  - `changefeed.checkpoint.total_bytes`, which measures the total size of a changefeed checkpoint in bytes.
  - `changefeed.checkpoint.span_count`, which measures the number of spans in a changefeed checkpoint. #139375
- The following schema changes are now allowlisted to run during LDR.
  - `ALTER INDEX RENAME`.
  - `ALTER INDEX .. NOT VISIBLE`.
  - `ALTER TABLE .. ALTER COLUMN .. SET DEFAULT`.
  - `ALTER TABLE .. ALTER COLUMN .. DROP DEFAULT`.
  - `ALTER TABLE .. ALTER COLUMN SET VISIBLE`. #141858
- Added `sql.statement_timeout.count` to track the number of SQL statements that fail due to exceeding the statement timeout. #142078
- Added the `sql.transaction_timeout.count` metric to track the number of SQL statements that fail due to exceeding the transaction timeout. #142105
- Added the `jobs.row_level_ttl.num_delete_batch_retries` metric to track the number of times the TTL job had to reduce the batch size and try again. #141953
- To create a logical data replication (LDR) stream, users require the `REPLICATIONDEST` privilege, instead of the `REPLICATION` privilege. #142345
- To create a physical cluster replication (PCR) stream, users require the `REPLICATIONDEST` privilege, in addition to the already required `MANAGEVIRTUALCLUSTER` privilege. #142345
- Removed the `kv.snapshot_receiver.excise.enable` cluster setting. Excise is now enabled unconditionally. #142651
- Introduced the cluster setting `server.child_metrics.include_aggregate.enabled`, which modifies the behavior of Prometheus metric reporting (`/_status/vars`). By default, it is set to `true`, which maintains the existing behavior. It can be sert to `false` to stop the reporting of the aggregate time series that prevents issues with double counting when querying metrics. #141601
- When configuring the `sql.ttl.default_delete_rate_limit` cluster setting, a notice is displayed informing that the TTL rate limit is per leaseholder per node with a link to the docs. #142061
- Added a new `envelope` type `enriched` for changefeeds. #140112
- Added support for the `enriched` envelope type to Avro format changefeeds. #140525
- The cluster setting `changefeed.new_webhook_sink_enabled`/`changefeed.new_webhook_sink.enabled` is no longer supported. The new webhook sink has been enabled by default since v23.2, and the first version webhook sink has been removed. #141940
- The cluster setting `changefeed.new_pubsub_sink_enabled`/`changefeed.new_pubsub_sink.enabled` is no longer supported. The new Google Cloud Pub/Sub sink has been enabled by default since v23.2, and the first version Pub/Sub sink has been removed. #141948
- `DROP INDEX` can now only be run when `sql_safe_updates` is set to `false`. #139456

### Command-line changes

- Improved the performance of the debug zip query that collects `transaction_contention_events` data, reducing the chances of `memory budget exceeded` or `query execution canceled due to statement timeout` errors. #139735
- Removed the deprecated `--storage-engine` parameter from the CLI. #139744

### DB Console changes

- The `/_admin/v1/settings` API (and therefore cluster settings console page) now returns cluster settings using the same redaction logic as querying `SHOW CLUSTER SETTINGS` and `crdb_internal.cluster_settings`. This means that only settings flagged as "sensitive" will be redacted, all other settings will be visible. The same authorization is required for this endpoint, meaning the user must be an `admin`, have `MODIFYCLUSTERSETTINGS`, or `VIEWCLUSTERSETTINGS` roles to use this API. The exception is that if the user has `VIEWACTIVITY` or `VIEWACTIVITYREDACTED`, they will see console-only settings. #138688
- The Overload dashboard in the DB Console now shows only the v2 replication admission control metrics, where previously it displayed both v1 and v2 metrics. Additionally, the aggregate size of queued replication entries is now shown. #139066
- Jobs can now choose to emit messages that are shown on the Jobs Details page in v25.1 and later. #139246
- An event is posted when a store is getting close to full capacity. #139199
- Percentile latencies are no longer available for SQL Activity. The implementation of these percentiles was error-prone and difficult to understand because it was computed differently from the other SQL statistics collected. Customers interested in viewing percentile latencies per statement fingerprint are encouraged to use the experimental per-fingerprint histograms that can be enabled with the `sql.stats.detailed_latency_metrics.enabled` cluster setting. This will enable externalized histogram metrics via the Prometheus scrape endpoint. #139500
- Surfaced commit latency on the Transactions pages #139946
- Removed the Paused Follower graph from the Replication dashboard in the DB Console as followers are no longer paused by default from v25.1. #141427
- DB console's `index.html` page now includes a Content-Security-Policy (CSP) header to help prevent malicious XSS attacks. #142282

### Bug fixes

- Previously, storage parameters with the same key would lead to ambiguity. This has now been fixed and an error surfaced if duplicate storage parameters are specified. #139172
- Fixed a bug where the error `batch timestamp T must be after replica GC threshold` could occur during a schema change backfill operation, causing the schema change job to retry infinitely. Now, this error is treated as permanent, and will cause the job to enter the `failed` state. #139203
- Previously, whenever CockroachDB collected a statement bundle when plan-gist-based matching was used, the `plan.txt` file would be incomplete. This bug is now fixed—it had been present since the introduction of the plan-gist-based matching feature in v23.1, but was partially addressed in the v24.2 release. #127604
- Previously, `EXPLAIN ANALYZE` of mutation statements would always get `actual row count: 1` execution statistic for the corresponding mutation node in the plan, regardless of how many rows were actually modified. The bug has been present since before v22.2 and is now fixed. #139278
- Fixed a bug where sometimes activating diagnostics for SQL activity appeared unresponsive, with no state or status update upon activating. Now, the status should always reflect that diagnostics are active or that a statement bundle is downloadable. #139342
- The `to_regclass`, `to_regtype`, `to_regrole`, and related functions now return `NULL` for any numerical input argument. #139777
- Fixed a rare bug in which a query might fail with the error `could not find computed column expression for column in table` while dropping a virtual computed column from the table. This bug was introduced in v23.2.4. #139388
- The optimizer could produce incorrect query plans for queries using trigram similarity filters (e.g., `col % 'val'`) when `pg_trgm.similarity_threshold` was set to `0`. This bug was introduced in v22.2.0 and is now fixed. Note that this issue does not affect v24.2.0 and later releases when the `optimizer_use_trigram_similarity_optimization` session variable (introduced in v24.2.0) is set to its default value `true`, as it would skip this behavior. #139265
- Fixed a bug that could cause `SHOW TABLES` and other introspection operations to encounter a `batch timestamp must be after replica GC threshold` error. #139532
- Fixed a bug that existed only in pre-release versions of v25.1. The bug could cause creation of a PL/pgSQL routine with a common table expression (CTE) to fail with an error like the following: `unexpected root expression: with`. #140083
- Configuring replication controls on a partition name of an index that is not unique across all indexes will correctly impact only that partition. #140167
- The Data distribution page in Advanced Debug will no longer crash if there are `NULL` values for `raw_sql_config` in `crdb_internal.zones`. #140066
- Fixed a bug where dropping a table with a trigger using the legacy schema changer could leave an orphaned reference in the descriptor. This occurred when two tables were dependent on each other via a trigger, and the table containing the trigger was dropped. #140995
- Addressed a bug that could cause concurrent DML operations to prevent primary key changes from succeeding. #141189
- Fixed a bug that prevented transaction retry errors encountered during implicit transactions from being automatically retried internally if the `autocommit_before_ddl` session variable was enabled and the statement was a schema change. #141369
- A step in the v25.1 upgrade finalization process that required backfilling jobs now uses locks to ensure it makes progress even when there is contention on the jobs table, which will prevent the possibility of becoming stuck under heavy load. #141420
- Fixed a bug that could prevent `SHOW CREATE TABLE` from working if a database was offline (e.g., due to a `RESTORE` on that database). #141195
- Fixed a bug that prevented starting multi-table logical data replication (LDR) streams on tables that used user-defined types. #141634
- Fixed a bug that could cause `nil pointer dereference` errors when executing statements with UDFs. The error could also occur when executing statements with some built-in functions, like `obj_description`. #141596
- Fixed a bug where a node that was drained as part of decommissioning may have interrupted SQL connections that were still active during drain (and for which drain would have been expected to wait). #141411
- Fixed a bug where the fraction completed and internal checkpoints during an index backfill operation would stop getting written if any of the periodic fraction/checkpoint write operations failed. Additional logging was added so that progress is logged in addition to being written to the job record. This bug affected schema change operations, such as creating an index or adding a non-nullable column to a table. #141714
- Fixed a bug that could cause gateway nodes to panic when performing an `UPSERT` on a table with a `BOOL` primary key column and a partial index with the primary key column as the predicate expression. #141728
- Fixed a bug where CockroachDB could incorrectly evaluate casts to some `OID` types (like `REGCLASS`) in some cases. The bug has been present since at least v22.1. #141946
- Transactions that enter the `aborted` state now release locks they are holding immediately, provided there is no `SAVEPOINT` active in the transaction. #140160
- Fixed a bug when running with `autocommit_before_ddl` that could cause a runtime error when binding a previously prepared DDL statement. #142034
- Fixed a bug where orphaned leases were not properly cleaned up. #141429
- Previously, the `CREATE LOGICALLY REPLICATED` syntax would always create the destination side table with the source side name, instead of the user-provided name. This change ensures the user-provided name is used. #142235
- Fixed a bug that would prevent `CREATE TRIGGER` and `DROP TRIGGER` statements from working if the `autocommit_before_ddl` setting was enabled, and if the statement was either sent as a prepared statement or as part of a batch of multiple statements. #142202
- Fixed a bug that could cause the upgrade to v25.1 to crash if a job was missing from the virtual table, for example, if a malformed job had no payload information. #142284
- The TTL deletion job now includes a retry mechanism that progressively reduces the batch size when encountering contention. This improves the chances of successful deletion without requiring manual adjustments to TTL job settings. #141953
- Fixed an issue where removed nodes could leave persistent entries in `crdb_internal.gossip_alerts`. #142385
- Invalid default expressions could cause backfilling schema changes to retry forever. #142490
- Fast failback could succeed even if the destination cluster's protected timestamp had been removed, causing the reverse stream to enter a crashing loop. This fix ensures the failback command fast fails. #142231
- Fixed an issue where dropping a database with triggers could fail due to an undropped back reference to a trigger function. #142670
- Fixed a bug where replication controls on indexes and partitions would not get properly updated during an index backfill (in the declarative schema changer) to its new ID; effectively discarding the replication controls set on it before the backfill. #141800
- Addressed a bug where `CREATE SEQUENCE` could succeed under with a `DROP SCHEMA` or `DROP DATABASE` in progress. #142696
- Fixed a bug in client certificate expiration metrics. #142682
- Physical cluster replication (PCR) reader catalogs could have orphan rows in `system.namespace` after an object is renamed. #142829
- Fixed a bug where during validation of a table-level zone configuration, inherited values were incorrectly populated from the default range instead of from the parent database. #142760
- Fixed a bug that would send a replica outside of a tenant known region, when `SURVIVE REGION FAILURE` was set and exactly 3 regions were configured. #142838

### Performance improvements

- Improved directory traversal performance by switching from `filepath.Walk` to `filepath.WalkDir`. #139108
- Removed a potential storage read from the Raft commit pipeline. This reduces the worst-case KV write latency. #139609
- The `optimizer_check_input_min_row_count` session setting now defaults to `1`, resulting in better query plans for foreign key and uniqueness checks. #140735
- This change restores the changefeed checkpoint immediately to the change frontier. This potentially reduces duplicate messages in the event that the frontier writes a checkpoint before it receives updates and covers the previous checkpoint from the aggregators, overwriting the checkpoint with less information. #139969

### Build changes

- Upgraded to Go v1.23.6. #140626
- Enabled the use of profile-guided optimization in the `cockroach` binary. #142697
- Upgraded to Go v1.23.7. #142698