Sql-Server

Category: sql-server

How to Enable the Debug Channel in Extended Events for the Query Thread Profile XEvent in SQL Sever 2014+

How to Enable the Debug Channel in Extended Events for the Query Thread Profile XEvent in SQL Sever 2014+

on June 19, 2017

Category: sql-server

Microsoft recently gave us a more lightweight way to trace data related to execution plan performance. As of SQL Server 2014 SP2, you can trace the query_thread_profile Extended Event.

Continue reading

When does a Snapshot Transaction Really Begin?

When does a Snapshot Transaction Really Begin?

on June 12, 2017

They say, “never read the comments” on the internet, but I’m lucky to get lots of interesting points and questions in my comments.

Continue reading

When does physical reads include read-ahead reads in SQL Server?

When does physical reads include read-ahead reads in SQL Server?

SQL Server has more than one way to pull pages in from disk for your queries. SQL Server can do a physical read of an 8KB page, or an extent of 8 ย of those 8KB pages.

Continue reading

Top 5 Misleading SQL Server Performance Counters

Top 5 Misleading SQL Server Performance Counters

on June 5, 2017

Perfmon counters are an excellent tool for monitoring and sometimes troubleshooting Microsoft SQL Server. But some counters can get you into trouble, because they don’t mean what many people think. Learn what to look out for in the world of widely-used perfmon counters.

Continue reading

Database Mirroring Counters Missing from Perfmon?

Database Mirroring Counters Missing from Perfmon?

Collecting perfmon counters from SQL Server databases where you are using database mirroring is a little tricky

The counters won’t behave “normally” until after you set up mirroring for a database.

Continue reading

Finding Queries that Cause Wait Stats in SQL Server

Finding Queries that Cause Wait Stats in SQL Server

You’ve got some troubling wait stats in SQL Server. How can you tell which queries are causing those waits?

Learn the pros and cons of different techniques to track down the cause of both common and tricky waits in SQL Server, including CXPACKET, PAGEIOLATCH, LCK, RESOURCE_SEMAPHORE, and THREADPOOL waits.

Continue reading

When a Nonclustered Index and Statistics Make a Query Slower

When a Nonclustered Index and Statistics Make a Query Slower

on May 24, 2017

Nonclustered indexes are awesome in SQL Server: they can get you huge performance gains.

But we can’t always create the perfect index for every query. And sometimes when SQL Server finds an index that isn’t quite perfect and decides to use it, it might make your query slower instead of faster.

Continue reading