SQL Server A to Z – User-Defined Functions

The alphabet is quickly winding down (so sad).  We’re up to the letter U and that stands for User-defined functions. What is a user-defined function (UDF)? A function is a unit of code that can accept parameters, perform some action or calculation, and then return the result of that action or calculation. A user-defined function, [...]

November 7, 2011  Tags: , ,   Posted in: T-SQL  One Comment

SQL Server A to Z – Query

Today’s post is brought to you by the letter Q.  In SQL Server, the biggest thing that Q stands for is Query.  Obviously that’s a mighty broad topic, so today I’m just going to go over some best practices for writing queries that I’ve learned over the years. Nuggets of T-SQL goodness List out the [...]

October 17, 2011  Tags: , ,   Posted in: T-SQL  No Comments

Applied SQL – You’ve got homework

Jen McCown (blog | twitter) is giving us homework. When I was a kid I didn’t like homework. It was always so boring. Well, except for the time I had to do a diorama on dinosaurs. Now that was fun. Kids don’t do dioramas anymore do they? Pity. Anywho, Jen has started a series on [...]

August 17, 2011  Tags: ,   Posted in: T-SQL  One Comment

SQL Server A to Z – GO

GO.  Such a simple word.  So fraught with meaning. OK, not really. The GO command isn’t a T-Sql statement, but rather a command that tools like SSMS and OSQL recognize as a batch delimiter.  The tool sees GO and knows it should send all the preceding statements since the last GO (or since the beginning [...]

August 5, 2011  Tags: , ,   Posted in: T-SQL  No Comments

TSQL Tuesday #20: T-SQL Best Practices

Once a month, on the 2nd Tuesday, the SQL Server online community has a virtual party of sorts called T-SQL Tuesday.  T-SQL Tuesday was started by Adam Mechanic (blog|twitter) back in 2009 and has been going strong ever since.  This month, I decided to crash the party with a submission of my own.  The topic-du-jour [...]

July 12, 2011  Tags: , ,   Posted in: T-SQL  2 Comments