SQL Server Query Optimization
Optimize servers and databases with SQL performance tuning tips from SolarWinds® DPA generative AI
Identify which SQL query to focus on optimizing with the help of response time analysis
SolarWinds® Database Performance Analyzer (DPA) is built to provide you with the fastest way to analyze SQL statements, identify the root cause of performance problems, show trends, and establish baselines for key performance metrics. With DPA and its 24/7 database monitoring, SQL query optimization is faster, easier, and more likely to be done right than if you try to do it on your own.
DPA’s insights on response time and wait time can help you quickly identify the problematic SQL queries, including slow queries, and index recommendations to help you solve them. Response and wait time are some of the most useful metrics to use to gain insights into SQL query performance. DPA collates the data of all SQL statements and helps rank them based on response time. This data is then displayed through easy-to-read bar graphs in the DPA Query Performance Analyzer’s Query Details page, offering insights into query runtime. When you go to this page, the Top Waits chart is prominently displayed at the top, showing the query’s execution time for the time period you select. This bar graph is color-coded by type of wait, with the option to see more detailed information, as well as possible resolutions, for each type of wait. This can help developers and database administrators (DBAs) identify which SQL query to focus on to optimize SQL database performance.
Speed up SQL query optimization with AI Query Assist
Rewriting a poorly performing query takes time. You’re digging through execution plans, experimenting with indexes, testing rewrites—round after round. SolarWinds DPA’s generative AI, AI Query Assist is built to cut through that cycle. It analyzes your SQL query and its execution plan, then returns clear, actionable rewrite suggestions designed to improve performance. Less trial and error. Faster resolution.
Here’s how it works: when you connect DPA to SolarWinds Observability SaaS through Platform Connect and enable AI Query Assist, you can open the Query Details page for any problematic Microsoft SQL Server or Oracle query, select an execution plan, and click Optimize SQL for Plan. DPA sends the query text and plan to a secure enterprise LLM. Platform Connect sends the query and plan to SolarWinds Observability SaaS, where they’re sanitized to mask any personally identifiable information before being passed to a secure enterprise LLM. It returns optimization suggestions—available right in the DPA interface for anyone with read privileges to review.
Monitor development, test, and production servers to solve SQL query issues before deployment
Far too often, SQL query code is not tested until late in the development and production process. Most of the time, application performance is put off until the deployment phase. This means developers won’t see how code is performing until it’s in use. If issues with performance are discovered then, the process of solving them and the delay in producing functional code can become a hassle and even a security risk.
With the SolarWinds SQL Query Analyzer solution in DPA, you can monitor development, test, and production servers with less than a 1% load, so you can begin your query optimization in SQL Server before deployment. This tool also lets you safely monitor SQL code performance in production. Using the DPA dashboard, developers can drill down into a production database to learn how code is performing and can begin working to resolve issues and test new code before it’s expected to be put into use. By incorporating application performance into development cycles, developers can better improve SQL performance.
Get all the information you need in easy-to-understand bar charts
DPA’s Query Performance Analyzer presents all the information you need about key performance indicators through easy-to-understand bar charts and associated alerts. Having easy access to this information can enable DBAs and application teams to reduce downtime, effectively optimize resources, and quickly identify which SQL query to focus on.
With DPA’s SQL Query Analyzer, you can get a unified view of database performance to help you isolate the root cause of a SQL performance issue typically in just a few clicks. With DPA’s straightforward, unified dashboard, you can monitor SQL Server, Oracle, DB2, MariaDB, Aurora, MySQL, PostgreSQL, Azure SQL, and SAP ASE from a single view. You can also monitor VMware with less than a 1% load.
With DPA, you can use a single pane of glass to see the direct correlation between system resources, helping simplify your SQL query optimization. With the SolarWinds DPA dashboard, you get an overview of all monitored instances and statuses for a full performance picture of your databases. You can also optimize SQL queries across those top RDBMS engines from the same single view using the SQL Query Analyzer.
Collect query plans in real time, so you can analyze them as needed
Query execution plans, also called query plans, tell you how an SQL query will be—or already was—executed. Since the automatically produced execution plans aren’t always optimal, it’s important to be able to look back at cached execution plans to determine if they need to be altered to optimize the SQL database.
SolarWinds DPA collects execution plans in real-time and links them with SQL statements, wait types, and other performance data. The data’s history is then stored by DPA, so you can watch for and get alerted on any changes to the plan that may have resulted in performance degradation. This data storage also means you can revisit the plan when needed to find exactly which execution plan was used.
DPA displays the plan graphically, with pop-up dialogs when hovering over specific steps. It also displays compilations and recompilations per second, which lets you see if executions are being reused. In addition to the important metrics DPA collects and displays, these clear visuals can help you pinpoint the reasons behind SQL query performance degradation.
Get More on SQL Query Optimization
Do you find yourself asking…
Start with the data, not a guess. SolarWinds DPA provides a prioritized list of your SQL queries based on response time and wait type, allowing you to identify which query to address first before making any code changes. After that, you can take impactful steps such as following DPA's index recommendations, examining execution plans for inefficient joins or table scans, and alleviating memory pressure by minimizing single-use query plans.
SolarWinds DPA’s table tuning advisors run daily analysis to catch both small and widespread issues, and AI Query Assist can generate rewrite suggestions for your most problematic queries in seconds. Better yet—tackle these issues during development, not after deployment. DPA can monitor dev, test, and production environments simultaneously with under 1% load, so you catch performance problems before users ever see them.
Start with the data, not a guess. SolarWinds DPA provides a prioritized list of your SQL queries based on response time and wait type, allowing you to identify which query to address first before making any code changes. After that, you can take impactful steps such as following DPA's index recommendations, examining execution plans for inefficient joins or table scans, and alleviating memory pressure by minimizing single-use query plans.
SolarWinds DPA’s table tuning advisors run daily analysis to catch both small and widespread issues, and AI Query Assist can generate rewrite suggestions for your most problematic queries in seconds. Better yet—tackle these issues during development, not after deployment. DPA can monitor dev, test, and production environments simultaneously with under 1% load, so you catch performance problems before users ever see them.
Make SQL query optimization easy
Database Performance Analyzer
- Use the Query Details page to easily visualize performance metrics for your SQL queries.
- Get actionable suggestions from table tuning advisors and AI Query Assist to improve your SQL query performance.
- Solve SQL query issues before deployment by monitoring development, test, and production servers.



