SQL Sysobjects

This SQL is helpful when searching for specific strings within SQL code. I have used this code to search in databases too many times to mention. It is especially helpful when looking at a legacy database that I have never looked at before when trying to find things.

A cryptarithmetic puzzle

A puzzle where a mathematical equation is written using letters instead of numbers. Each letter represents a digit from 0 to 9, and no two letters can represent the same digit.
TOO + TOO + TOO + TOO = GOOD

Demo Cryptarithmetic

CSS Graph Paper Background

Nice and dark graph for printing graph paper. May need to adjust the 4th parameter of the rgba function to make the lines lighter.

Visualize SQL XML Execution Plan using HTML

I’ve always used the Microsoft SQL Management Studio Execution plan feature to visualize the query plan. However today I was experimenting with the SQL XML showplan statement to see if I could learn anything more about execution plans by looking more closely at the code. As soon as I saw the XML it occurred to me that I could use XSLT to convert the output to HTML similar to the way that the SQL Management studio did it. I was curious to try, but before I writing my own, I checked to see if anyone else did it already and found this on github:

So, to demonstrate I created a simple SQL using temp tables so that I could perform some very basic tests.

Insert some sample data

Turn on the SHOWPLAN_XML in SQL and run query to produce the XML.

Then copy and paste the output XML data into a file and upload to the demo page that uses Justins HTML query plan visualizer library.

HTML XML Upload demo