Month: April 2013

May is DBCC Command Month at

For the entire month of may, I will be featuring one DBCC Command each day on my blog. Come back for your daily dose of DBCC commands. Tomorrow (May 1st) I will cover DBCC CheckAlloc, followed by 30 more days

Posted in DBCC Commands Tagged with: , ,

Working on the next beta of the Database Health Reports… Any requests?

I am currently working on the next beta of the Database Health Reports.  I you haven’t seen the program check it out at I am looking for idea of new features to add in the next beta, and I

Posted in Database Health Tagged with: , ,

Index Overview – Clustered and Nonclustered

This is intended as a brief overview of indexing on SQL Server. Understanding and using indexes can lead to some major performance improvements. Non-Clustered Indexes Non-Clustered indexes are often times considered traditional indexing – contains pointers to the data. This

Posted in Performance Tagged with: , , , , , , ,

T-SQL: A Simple Example Using a Cursor

For more information on cursors, also take a look at the free SQL query training provided by Steve Stedman. In SQL Server the cursor is a tool that is used to iterate over a result set, or to loop through each

Posted in SQL 2008, SQL 2012, TSQL Tagged with: , , , , , , ,

Recursive Scalar Function in T-SQL

In my Common Table Expressions presentation the topic of recursion often comes up, but for scalar functions in T-SQL, it might not be as common. This article has been written to show how a scalar function in SQL Server can

Posted in TSQL Tagged with: , , , , , , , , ,


Here is a quick rundown on the T-SQL DATEPART function for SQL Server. DATEPART is used to pull a single part of a date/time element out as shown below. The following query uses DATEPART to extract the year from the

Posted in TSQL Tagged with: , , , , ,

Installing Sample Databases for SQL Server 2008R2

As I work on testing the Database Health Reports project, I have configured several test servers running as virtual machines using Hyper-V. Part of setting these up for testing, I usually end up installing the sample databases for SQL Server.

Posted in SQL 2008 Tagged with: , , , , ,

Database Health Reports Beta 5 is Going Strong

The Database Health Reports project is going strong. Database Health Reports is a free application for monitoring the key metrics on your SQL Server. Created by Steve Stedman. Database Health Reports Includes Wait time monitoring. Once installed, keeps a historic record the

Posted in Database Health Tagged with: , , , , , , ,

Common Table Expression accepted for SQL Saturday 212 in Redmond WA

My Common Table Expression presentation was accepted for SQL Saturday 212 in Redmond WA. This is the session that I am the most familiar with, and that I have presented the most times. I think this will be the 8th

Posted in CTE, SQL Saturday, TSQL Tagged with: , , , ,


SQL Server 2012 adds a new function called DateFromParts.  This new function simplifies the creating of a DATE type in TSQL over the older ways of doing it. The information here has been extracted from my SQL Saturday presentation on Whats New in

Posted in 70-461 Training, SQL 2008, SQL 2012, SQL 2014, TSQL, TSQL 2012 Tagged with: , , , , , , , ,