[WEBINAR] The New Normal: Dealing with the Reality of an Unsecure World

How do engineers monitor SQL queries?


How do engineers monitor SQL queries?


Most modern applications are database driven. Therefore, SQL queries are at the heart of all activities. Monitoring the activities of each and every query, whether simple or complex, is crucial. It is possible for a simple query to consume too many resources and slow down the entire system, so proper monitoring and health checkups are essential for all queries running in the system.

Before monitoring and analyzing SQL queries, engineers should have a proper understanding of performance metrics, their standard values and their relation with other similar metrics and resource-intensive processes.

Here are some of the ways engineers can monitor SQL queries and their performance:

  • Monitoring solution – A proper monitoring solution gathers all the data like CPU usage, processor time (%), database I/O and query execution time for the relevant metrics. Based on the data and metrics analysis, proper alerts can be set at different threshold points.
  • Activity monitor – An activity monitor is a very efficient tool for SQL Server monitoring. It is used to get information about metrics such as database I/O, waiting time, query execution time and processor time. All the details are shown in the form of a real-time graph. It is a live monitoring system which engineers can use to track queries in real time and take necessary actions whenever required. It is also very helpful to track expensive queries, which helps in identification and modification processes.
  • Data collection – Data collection is a tool focused on monitoring performance metrics. It also provides information on query statistics. This tool is configured to start collecting data on query statistics, and once configured, it collects data on expensive queries and other related information (based on the configuration). The data can be exported to PDF, Excel or other formats as a report.
  • Performance Monitor – Windows Performance Monitor (Perfmon) is another general-purpose server monitoring tool, which helps in monitoring CPU usage, disk I/O and memory usage. It also provides information on SQL Server as a separate counter. It allows DBAs and SQL engineers to easily track server performance.
  • SQL Monitor – This is also another SQL monitoring tool for measuring SQL query performance. It is mainly applicable for SQL servers.
  • SQL Profiler – SQL Profiler is a tool to identify query performance. It also helps in diagnosing and resolving performance issues. Engineers create a profiler trace to identify slow-running queries and then improve the performance of individual queries.

Apart from the above-mentioned tools and processes, there are other techniques which also help in monitoring SQL queries. They include other sets of SQL queries, stored procedures or DB tasks scheduled for monitoring. These tasks run as per schedule and provide reports on SQL performance.

Have a question? Ask Kaushik here.

View all questions from Kaushik.

Kaushik Pal

Kaushik is a technical architect with 15 years of experience in enterprise applications and product development. He has expertise in Web technologies, architecture/design, Java/J2EE, open source and Hadoop/big data technologies.

 Full Bio
Free Whitepaper: The Path to Hybrid Cloud
Free Whitepaper: The Path to Hybrid Cloud:
The Path to Hybrid Cloud: Intelligent Bursting To Amazon Web Services & Microsoft Azure
Free E-Book: Public Cloud Guide
Free E-Book: Public Cloud Guide:
This white paper is for leaders of Operations, Engineering, or Infrastructure teams who are creating or executing an IT roadmap.
Free Tool: Virtual Health Monitor
Free Tool: Virtual Health Monitor:
Virtual Health Monitor is a free virtualization monitoring and reporting tool for VMware, Hyper-V, RHEV, and XenServer environments.
Free 30 Day Trial – Turbonomic
Free 30 Day Trial – Turbonomic:
Turbonomic delivers an autonomic platform where virtual and cloud environments self-manage in real-time to assure application performance.


  • E-mail is not a threat. (Postal mail) is universal. The Internet is not.
    - USPS spokesperson Susan Brennan, in a 2001 Wired article.