Skip to Content

Utility Posts

Utility to temporarily drop FOREIGN KEY constraints on a set of tables

Posted June 15, 2017


I was working on a database a few weeks back (maybe longer, I am kind of busy with several projects right now), and I wanted to truncate a set of tables. There... more »

Utility to script a FOREIGN KEY Constraint

Posted May 24, 2017


Note: Amended to include the word include in the first Note (I am a terrible editor of my own writing!) and to fix a bug in the code with a misplaced... more »

Utility Queries–Structure of Tables with Identity Column

Posted September 02, 2012


Edit: At the suggestion of a much knowledgable commenter who shall remain named Aaron, I changed from using schema_name() function to using... more »

Utility Queries–Column Metadata

Posted April 22, 2012


Very often, I find myself wanting to query system metadata for columns. Some of the metadata is fairly easy to deal with, like if you want to find column... more »

Utility Objects Series Introduction (but mostly a bit of an update)

Posted March 11, 2012


So, I have been away from blogging about technical stuff for a  long time,  (I haven’t blogged at all since my resolutions blog, and even my Simple... more »