Category: Applied SQL

Code that writes code

Code that writes code it one of the best productivity tips I can give you.  And no, I’m not talking about ORMs. I’m specifically talking about YOU writing a query, which writes one or more queries. The example I’ll give today is changing database file growth rates. If I want to change the DB file growth […]

An MCM teaches COMMENTS at SQL Saturday OKC

Edit: SQL Sat OKC has come and gone, but the new session on comments is recorded and up on the MidnightDBA Events page! (Direct link to WMV.) Tomorrow (as of the blog’s publish date) at8:30am, I will be teaching “T-SQL’s Hidden Support Feature” at SQL Saturday Oklahoma City (totally free, did you know? Free IT training, y’all.) I said […]

Tricky TSQL: NOT IN (NULL)

We’ve done this before, but we can go one better this time. Let’s take this step by step. NULL means “I don’t know”. It stand for an unknown value. Nothing can be equal to NULL. We simply can’t say that 1 = NULL, or ‘ABBA’ = NULL,  because we don’t know what value NULL might possibly be […]