Too many “To Dos” and not enough “Dones”

I love taking on new projects, and I’m a do-it-yourself kind of person. If there is something that needs to be done around the house, I don’t hire it out, I do it myself. It’s not just physical stuff, either. That DIY mentality applies to everything in my life … doing taxes, starting businesses, writing websites/software, & designing logos. I really try to tackle all of these things myself.

However, as of lately, I’ve been feeling stretched really thin; too thin, actually. My “To Do” list hasn’t been getting items moved over to the “Done” side very quickly. Two of the bigger items on that list have been a pair of websites, my personal website and my wife’s business website, that both need similar functionality. I’ve written both from scratch and included a lot of really cool features on both. But the features are always taking me more & more time to add which is taking away from being able to get anything else done. The biggest feature is a blog engine. Now I know there are a ton of free blogging services out there, but I was really enjoying writing my own and figuring out all the nuances. And it has been a really fun challenge. But I need to let them go.

So I am deciding to change my focus a bit and give up control of having to do everything myself. That means that I will be transitioning both of the websites over to WordPress. It’ll cost a little bit more money than what it currently does, but the opportunity cost of being able to work on other things will far outweigh cost of switching over. Plus I’ll have more time to actually write content for the blog instead of the piping for it. And my wife will absolutely love the WordPress app for her iPhone. That alone should be the biggest reason to move.

With this change I will be losing some of my pride of creativity and accomplishment, but honestly, I’ll get those back with my next project. Move two more “To Dos” over to the “Done” column.

Advertisements

AutoRecover SQL Scripts

This morning, when I came into work, I discovered that Windows Update had graciously restarted my machine for me. No big deal. But wait, then I realized I had some SQL work that I hadn’t saved yet. NOOOOOO!!! I know, I know, … always save your work. But yesterday, I didn’t. So you can imagine how irritated I was to discover that all of that hard work was gone. Or so I thought.

A co-worker heard me getting mad at myself and chimed in that SQL Server Management Studio (SSMS) has an autorecover feature. WHAT!? Yep, when ever you start typing a query in SSMS, a file is automatically created and saves itself every 5 minutes. The location of this AutoRecover document is located in “\My Documents\SQL Server Management Studio\Backup Files\Solution [n]\”. The [n] represents an integer that corresponds to how many SSMS IDE windows you have open. I only had one IDE open, with two query windows open, so I had a “\Solution 1\” folder with two files in it: ~AutoRecover.~vs47E8.sql & ~AutoRecover.~vsD5FD.sql.

Try it out. Open the folder mentioned above and open a new SSMS IDE and Query window and start typing out a quick SELECT. After about 5 minutes, you will see a new file prefixed with “~AutoRecover.~vsXXXX.sql”. The X’s are alphanumeric values that change with every file. The new file will get auto saved in 5 min increments from there on. When you close SSMS or a query window and it asks you if you want to save, click No, and watch the auto-generated file delete itself.

Wow, that was a HUGE relief. SSMS 2005 and higher has this feature built in. Thank you Microsoft for saving me from my own carelessness.

Free eBook: Defensive Database Programming

Simple-Talk Publishing has released a new free eBook: Defensive Database Programming with SQL Server, by Alex Kuznetsov.

The goal of Defensive Programming is to produce resilient code that responds gracefully to the unexpected. To the SQL Server programmer, this means T-SQL code that behaves consistently and predictably in cases of unexpected usage, doesn’t break under concurrent loads, and survives predictable changes to database schemas and settings.

Too often as developers, we stop work as soon as our code passes a few basic tests to confirm that it produces the ‘right result’ in a given use case. We do not stop to consider what other possible ways in which the code might be used in the future, or how our code will respond to common changes to the database environment, such as a change in the database language setting, or a change to the nullability of a table column, and so on.

This book is filled with practical, realistic examples of the sorts of problems that beset database programs, including:

  • Changes in database objects, such as tables, constraints, columns, and stored procedures.
  • Changes to concurrency and isolation levels.
  • Upgrades to new versions of SQL Server.
  • Changes in requirements.
  • Code reuse.
  • Problems causing loss of data integrity.
  • Problems with error handling in T-SQL.

You can download the eBook in PDF format here.