THE SQL Server Blog Spot on the Web

Welcome to - The SQL Server blog spot on the web Sign in | |
in Search

Browse by Tags

All Tags » performance » Query Tuning   (RSS)
  • Automating dm_exec_query_stats and dm_db_index_usage_stats analysis

    Everyone should know by now how really useful the DMVs dm_exec_query_stats, and dm_db_index_usage_stats and the associated DMFs for obtaining the SQL and XML plan: dm_exec_sql_text, dm_exec_query_plan, and dm_exec_text_query_plan. Of course it has been explained that dm_exec_query_stats is not a replacement for SQL Server Profiler and SQL Trace. ...
    Posted to Joe Chang (Weblog) by jchang on June 22, 2009
  • Why Logical IO is a poor performance metric

    Many years ago, I attended a conference where a very highly respected Oracle performance expert advocated the use of logical IO count as a performance metric. The argument was that a logical IO is a fairly substantial operation relative to others. I suppose that detailed logical IO was already collected supported this. So why would logical IO be ...
    Posted to Joe Chang (Weblog) by jchang on September 10, 2008
  • Who's On First? Solving the Top per Group Problem (Part 1: Technique)

    Relative comparison is a simple matter of human nature. From early childhood we compare and contrast what we see in the world around us, building a means by which to rate what we experience. And as it turns out, this desire to discover top and bottom, rightmost and leftmost, or best and worst happens to extend quite naturally into business ...
    Posted to Adam Machanic (Weblog) by Adam Machanic on February 8, 2008
  • Medians, ROW_NUMBERs, and performance

    A couple of days ago, Aaron Bertrand posted about a method for calculating medians in SQL Server 2005 using the ROW_NUMBER function in conjunction with the COUNT aggregate. This method (credited to Itzik Ben-Gan) is interesting, but I discovered an even better way to attack the problem in Joe Celko's Analytics and OLAP in SQL.Rather than using a ...
    Posted to Adam Machanic (Weblog) by Adam Machanic on December 18, 2006
  • Exploring the secrets of intermediate materialization

    When working with SQL Server 2000, I used to have this little trick I'd pull out after exhausting all other ideas for tuning a query.  And I thought that my little trick was dead in SQL Server 2005, but thanks to fellow SQL Server MVP Rob Farley, I am officially reviving my trick from the dead here and now, in this blog post.... But first, ...
    Posted to Adam Machanic (Weblog) by Adam Machanic on October 3, 2006
  • Scalar functions, inlining, and performance: An entertaining title for a boring post

    Scalar.  Function.Wow.Could any other combination of words evoke the same feeling of encapsulation, information hiding, and simplification of client code?  After years spent developing software in the procedural and OO worlds, it can be difficult--perhaps, even impossible--to migrate over to working with SQL Server and not consider how ...
    Posted to Adam Machanic (Weblog) by Adam Machanic on August 3, 2006
  • Paging in SQL Server 2005

    I keep seeing questions on newsgroups about paging in stored procedures, and whether there will be a better way in SQL Server 2005. However, aside from a few answers in newsgroups, I haven't seen any content on how to do it. So I'd like to spend a few minutes and share with you the new features that will make paging stored procedures ...
    Posted to Adam Machanic (Weblog) by Adam Machanic on November 3, 2004
Privacy Statement