Several times I have run into a conversion where I have needed to take a table that stores key value pairs into a table that lists all values for a given record. The table look something like this: What I really wanted was something like this: This is kind of…
Continue reading: Converting a Hash Map to a TableCategory: Informational
Okay, now that we have the general framework we can start writing the pieces that deal with the values that were given to us in the puzzle. The first thing I’m going to do is create a table that contains each possible value for each cell based on the values…
Continue reading: Solving Sudoku in One SQL Query – Part 3 – Solving the PuzzleIn this post, I’ll be diving deep into the code that was presented in this post. Recursive CTEs My solution utilizes a lot of recursive common table expressions (CTEs). CTEs are a simple way of defining a temporary projection in T-SQL that can be referenced multiple times later on in…
Continue reading: Solving Sudoku in One SQL Query – Part 2 – Creating the FrameworkI’ve seen a couple examples of using SQL to solve sudoku puzzles, but most of the ones I’ve seen have used loops or cursors to cycle through and create a correct answer. I feel like if you make a solution that’s procedural like that, you might as well have done…
Continue reading: Solving Sudoku in One SQL Query – Part 1One of the things that I’ve commonly run into when I am working on a data conversion is an issue where I want to delete everything from a table, but there are foreign keys pointing to that table, and then there are foreign keys pointing to the tables with the…
Continue reading: SQL Cascade Delete without CascadeSo my friends asked me to send out some tips for how I set up my email and I got some good feedback from it, so I guess I’ll post this next one on my blog… I have been using gmail’s new Priority Inbox for some time now and I…
Continue reading: Gmail ProTips #2 – Priority InboxI know some of you wanted more deets on filtering spam and such, so here’s my set up that seems to work pretty well. What you mainly need to know is that you can add a + to the end of your gmail name and add whatever you want and it will…
Continue reading: Gmail ProTips #1 – Infinite Email Addresses