DateTime2 not like DateTime

I came across an article on SQL Server Central written by Claudio Silva (b/t) discussing that you can't do arithmetic operations on DateTime21 like you can with DateTime. For example: Old Way OrderDate < GETDATE() -1 You need to do something like this: OrderDate...

read more

T-SQL Tuesday #101: Tools I forgot

The 101st addition to the SQL monthly blog party is being hosted by Jens Vestergaard (b/t). For the topic this month, Jens has asked which tools are essential to our daily job. Or rather, which tools do I depend on as a DBA. Interesting Topic I would love to say I...

read more

Space: Unused vs Unallocated

I had previously blogged about working on a SQL job that deleted data older than 13 months. Today I thought I would follow up with the database and check to see how much space was available in the database. So I ran a disk usage report out of SSMS and got the...

read more

Getting whipped by GetDate()

I have recently been working on tuning a job that purges data out of various tables that are older than 13 months using getdate. Pretty straight forward right? Well originally the job consisted of 6 different statements like so: delete from table1 where...

read more

TSQL Tuesday #99 – Outside Interests

This month, Aaron Bertrand (b/t) is hosting the TSQL Tuesday topic. And this month, the topic of choice is either 1) an outside hobby or 2) bad habits found/used in TSQL. I somehow think by the time I’m done with this post, I’m going to blur the two together....

read more

A Month of SSMS

One of the things that has always frustrated me with Microsoft's tools like SSMS and Visual Studio, is the sheer depth of the tool. Figuring out how to create an SSRS or SSIS package in Visual Studio the first few times can result in half a day wasted. SSMS can be...

read more

Error 18456 State x

I use this link all the time to troubleshoot login errors in the SQL error log. Aaron Bertrand recently moved his blog, so I wanted to make sure I had an updated link for my reference.

read more

Oh look, another New Year…

Yes, it's January already and that means it's a New Year. Which means, it's that time of year for reviews of the last year, resolutions for the new year, and hope springs eternal. Only, this year I haven't had time to look up to do a year in review, and I'm not...

read more


By continuing to use the site, you agree to the use of cookies. more information

The cookie settings on this website are set to "allow cookies" to give you the best browsing experience possible. If you continue to use this website without changing your cookie settings or you click "Accept" below then you are consenting to this.