Stay organized with collections Save and categorize content based on your preferences.
This page describes the Cloud SQL for SQL Server index advisor and how you can view and apply its index recommendations.
Cloud SQL for SQL Server offers a fully managed index advisor that tracks the queries your database handles regularly. Periodically, the index advisor analyzes these queries to recommend new indexes that can improve query performance. The index advisor lets you detect and fix performance issues with systems and queries.
How does the index advisor work?The index advisor helps you improve query processing by doing the following:
The index advisor stores and displays the
CREATE INDEX
command containing the database name, schema name, table name, and column names. The tracked queries are all normalized queries with all literals removed.
Index recommendations are encrypted at rest.
LimitationsCloud SQL for SQL Server index advisor has the following limitations:
CREATE INDEX
recommendations only.To obtain index advisor recommendations, you must use Cloud SQL Enterprise Plus edition and enable query insights for Cloud SQL Enterprise Plus edition for your Cloud SQL instance.
Required roles and permissionsTo get the permissions that you need to obtain index advisor recommendations, ask your administrator to grant you the Cloud SQL Viewer (roles/cloudsql.viewer
) IAM role on the project that hosts the Cloud SQL instance. For more information about granting roles, see Manage access to projects, folders, and organizations.
This predefined role contains the permissions required to obtain index advisor recommendations. To see the exact permissions that are required, expand the Required permissions section:
Required permissionsThe following permissions are required to obtain index advisor recommendations:
databaseinsights.recommendations.query
databaseinsights.resourceRecommendations.query
You might also be able to get these permissions with custom roles or other predefined roles.
Enable index advisor recommendationsWhen you enable query insights for Cloud SQL Enterprise Plus edition, you enable index advisor recommendations automatically.
Disable index advisor recommendationsYou can't disable index advisor recommendations without disabling query insights for Cloud SQL Enterprise Plus edition.
To disable index advisor recommendations and query insights for Cloud SQL Enterprise Plus edition, see Disable query insights for Cloud SQL Enterprise Plus edition.
View index advisor recommendationsCloud SQL automatically runs the index advisor analysis periodically. To view index advisor recommendations, use the Query insights dashboard.
View and filter recommendations in the Query insights dashboardIn the Google Cloud console, go to the Cloud SQL Instances page.
CREATE INDEX
recommendations, add a filter for Recommendation: Create Indexes.To view index recommendations for a specific query, follow these steps:
In the Google Cloud console, go to the Cloud SQL Instances page.
In the Google Cloud console, go to the Cloud SQL Instances page.
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-08-14 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-14 UTC."],[],[]]
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4