Category Archives: T-SQL
-
Name the schema when you create an object (or else)
1April 6, 2016 by Kenneth Fisher
This is one of those frequently ignored best practices. When you create an object, specify the schema where it will …
Continue reading -
Complex/Conditional ORDER BYs
1April 4, 2016 by Kenneth Fisher
Typically it’s considered best to run your queries without an ORDER BY and let the application do any sorting needed. …
Continue reading -
Hidden code in AdventureWorks
4April 1, 2016 by Kenneth Fisher
I’ve playing around with AdventureWorks and managed to found some hidden code! Truly odd stuff. I’m so shocked I couldn’t …
Continue reading -
Why you shouldn’t use SELECT *
1March 28, 2016 by Kenneth Fisher
I answered an interesting question on SE today (ever notice how many posts come from stuff I read on forums?) …
Continue reading -
TOP 1 killed my performance; Rob Farley helped me resurrect it.
15March 21, 2016 by Kenneth Fisher
tl;dr; There is no short version of this. It’s LONG. It’s interesting but you might want to skip it if …
Continue reading -
Take caution when altering a column using TSQL
1February 17, 2016 by Kenneth Fisher
When developing in SQL Server you are eventually going to have to modify a column or two (at least). And …
Continue reading -
varchar(1) VS char(1)
3February 15, 2016 by Kenneth Fisher
The other day I made a somewhat flip coment on twitter. (I know, everyone is shocked right?) varchar(1) Really? It’s …
Continue reading -
To the page and back again
1January 18, 2016 by Kenneth Fisher
To the page It’s not one of those things you have to do frequently but every now and again you …
Continue reading -
What is RESULT SETS?
11January 14, 2016 by Kenneth Fisher
I was reading some code the other day and it included the statement RESULT SETS. I’d never seen it before …
Continue reading -
What does that N in nvarchar really mean?
9December 28, 2015 by Kenneth Fisher
In any study of Data Types in SQL Server you are going to have to look at the various string …
Continue reading




