Skip to content

Say that Query Store for readable secondaries is off by default in SQL Server 2025 - #10445

Open
Rudi Bruchez (rudi-bruchez) wants to merge 2 commits into
MicrosoftDocs:livefrom
rudi-bruchez:fix/whats-new-2025-query-store-secondaries
Open

Rudi Bruchez (rudi-bruchez) wants to merge 2 commits into
MicrosoftDocs:livefrom
rudi-bruchez:fix/whats-new-2025-query-store-secondaries

Conversation

@rudi-bruchez

Copy link
Copy Markdown
Contributor

What's wrong

The "Query Store and intelligent query processing" table of What's new in SQL Server 2025 says of Query Store for readable secondaries: "Now on by default."

The feature page, Query Store for readable secondary replicas, has said since February 2026 that SQL Server 2025 is "Yes" for available and "No (can be enabled, per database)" for enabled by default, and that the feature is in preview. The measurement agrees with the feature page. The What's new line dates from the original 2025 release text and wasn't updated with it.

Evidence

SQL Server 2025 CU9-GDR (17.0.5015.4), Enterprise Developer, Linux containers. Availability group with CLUSTER_TYPE = NONE, two synchronous-commit replicas, automatic seeding, SECONDARY_ROLE (ALLOW_CONNECTIONS = ALL). Two databases: one restored from a SQL Server 2022 backup (Query Store READ_WRITE on the primary, compatibility level 170), and one created on 2025 and added to the group:

-- on the primary
CREATE DATABASE BaseNeuve;
ALTER DATABASE BaseNeuve SET RECOVERY FULL;
BACKUP DATABASE BaseNeuve TO DISK = N'/var/opt/mssql/backup/BaseNeuve.bak' WITH INIT;
ALTER AVAILABILITY GROUP AGLecture ADD DATABASE BaseNeuve;

-- on the secondary, ApplicationIntent=ReadOnly, in each database
SELECT desired_state_desc, actual_state_desc, readonly_reason, query_capture_mode_desc
FROM sys.database_query_store_options;

Observed for both databases on the secondary: desired_state_desc OFF, actual_state_desc OFF, readonly_reason 8. Queries run on the secondary aren't recorded. After ALTER DATABASE ... FOR SECONDARY SET QUERY_STORE = ON (OPERATION_MODE = READ_WRITE) on the primary, the secondary reports READ_CAPTURE_SECONDARY and its queries reach the primary's Query Store with replica_group_id 2.

Re-run on 2026-10-20 on a fresh pair of 2025 CU9-GDR (17.0.5015.4) containers, same group settings, with a database created on 2025: the secondary reports OFF, OFF, readonly_reason 8 until the FOR SECONDARY statement, then READ_CAPTURE_SECONDARY; with QUERY_CAPTURE_MODE = ALL for the secondary, a query run there appears in sys.query_store_query_text on the primary.

Expected per the current text: Query Store on by default on the secondary.

Change

Replaces "Now on by default." with a short description that says the feature is in preview and is enabled per database with ALTER DATABASE ... FOR SECONDARY SET QUERY_STORE = ON, as the feature page describes.

…L Server 2025

The What's new table says the feature is now on by default, while the feature page has listed SQL Server 2025 as not enabled by default, can be enabled per database, since February 2026. Measured on SQL Server 2025 CU9-GDR in an availability group, the secondary reports Query Store OFF until ALTER DATABASE ... FOR SECONDARY is run, for a database restored from 2022 and for one created on 2025.
@prmerger-automator

Copy link
Copy Markdown
Contributor

Rudi Bruchez (@rudi-bruchez) : Thanks for your contribution! The author(s) and reviewer(s) have been notified to review your proposed change. Randolph West MSFT (@rwestMSFT)

@prmerger-automator

Copy link
Copy Markdown
Contributor

Rudi Bruchez (@rudi-bruchez) : Thanks for your contribution! The author(s) and reviewer(s) have been notified to review your proposed change. Randolph West MSFT (@rwestMSFT)

@learn-build-service-prod

Copy link
Copy Markdown
Contributor

Learn Build status updates of commit 6d09bda:

✅ Validation status: passed

File Status Preview URL Details
docs/sql-server/what-s-new-in-sql-server-2025.md ✅Succeeded

For more details, please refer to the build report.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

The documentation correction and enablement guidance are accurately reflected.

No open issues 🎉

What changed in this PR

Updates SQL Server 2025 documentation to clarify that Query Store for readable secondaries is a preview feature disabled by default.

Changes:

  • Replaces the incorrect “Now on by default” statement.
  • Adds per-database enablement guidance.
File Description
docs/​sql-server/​what-s-new-in-sql-server-2025.md Corrects Query Store for readable secondaries availability and configuration details.

Review effort: Lite

@Court72

Copy link
Copy Markdown
Contributor

William Assaf MSFT (@WilliamDAssafMSFT)

Can you review the proposed changes?

Important: When the changes are ready for publication, adding a #sign-off comment is the best way to signal that the PR is ready for the review team to merge.

#label:"aq-pr-triaged"
@MicrosoftDocs/public-repo-pr-review-team

@Court72 Courtney Wales (Court72) added the aq-pr-triaged tracking label for the PR review team label Oct 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants