Using the Output Clause with T-SQL Merge

The Output clause, first implemented in SQL Server 2005, can be used to return information for each row modified by an Insert, Update, Delete or Merge statement. This functionality greatly increases the power and usefulness of Merge, and is required in the processing of Slowly Changing Dimensions.

This post is the second in a […]

Rock the Vote... or Something.

Let me just start this post with an apology to all of my readers, well both of you. There have been a lot of changes in my life lately and I’m been overwhelmed with demands on my time. I won’t go into details but those demands will be letting up soon, and I will […]

What is the T-SQL Merge Statement and How do you use it?

I mentioned in a previous article that many posts on T-SQL Merge read like Books Online. Speaking of Books Online, let’s start by glancing at the syntax portion of the T-SQL Merge Page. I’ll take the liberty of re-posting just the first 25% or so below.

[ WITH [,…n] ]

SQL Saturday Dallas and Pre-Cons

The North Texas SQL Server User Group recently announced our next SQL Saturday. SQL Saturday 163 will be another business intelligence centric event, with a limited number of attendees. The last time we had an event like this, it sold out in less than 12 hours, so I’d urge everyone to sign up right away.

I […]

Presenting at SQL Saturday Houston

This Saturday I’ll be down in Houston presenting at SQL Saturday #107. I can’t wait to hang out with some of the best minds in SQL Server, which just happen to be great friends of mine as well. The abstract for my session is below.

Data Warehousing – How to Convince “The Bobs”

I […]

Why I Chose to Become a Business Intelligence DBA

Recently I’ve received several emails with the same basic theme. I was sought out because I am a Business Intelligence Consultant and they want to know whether the career would be good for them. Well, it’s hard to read a short synopsis of someone’s experience and recommend a life altering directional change. So, I decided […]

State Name and Abbreviation Lookup Table Script

This is a quick script which creates a table consisting of State Names and their corresponding Abbreviations. I use this table when doing basic data quality checking and also standardizing state designations.

CREATE TABLE dbo.StateLookup
StateID INT IDENTITY (1, 1),
StateName VARCHAR […]

Free Support Can Cost a Fortune

While performing some SQL programming work for a client they mentioned a problem they had with a vendor. I won’t name the vendor but I will say that it rhymes with Made2Damage. Anyway, the client spent most of the day trying to fix a problem with the help of telephone support. Hours were spent on […]

The Made2Manage Favorites Bar Must Die

As I’ve mentioned before, the Made2Manage Favorites Bar is a buggy mess. I regularly get questions from my clients and readers of this blog asking why M2M screens return incorrect data or otherwise misbehave. One of my first suggestions to them is to disable the favorites bar. However, disabling the bar isn’t intuitive so I […]

This One Time... At PASS Camp...

Like many of you, I have been finalizing my PASS Summit plans, getting ready for the trip to Seattle.

For the past week, my girlfriend has been asking weird questions like, “Have you packed your sun screen?” This makes no sense because there’s no way I’ll get a sunburn in Seattle in October. When I […]