Geeks With Blogs
rusty "Razorblade" coslett stainless musings
Hearing both of these guys (Paul Nielsen and Louis Davidson) together was awesome (another DevLink Nashville plug).  They share common views, but also differ on a few things which was really nice to hear.  Even the experts have their own ideas which leaves room for us common folk.  No absolutes, lots of grey or gray depending on which side of the pond you find yourself (someone's commentary here).

A few items that I knew were bad are cursors among others.  I liked the bantering of normalization pros/cons and at what level to stop.  I guess Amazon will get some more money from me for their books.

The nicest detail was that they were both keen on sharing the idea of 'try it and see' (my words not theirs).  You might be normalizing and tweaking performance based on your own understanding, but database engines are smart and were written by people knowing that we are human and not everyone will be an expert.

I have to apply this to myself when writing queries or .net code simply because I tend to run too far, too fast with 'my' optimizing.  I tend to lose my original intent which causes me to backtrack and spend time finding all of my flawed fork-in-the-road choices.

Here are a few concepts that before I knew them, made querying difficult.

  • Analyzing the Actual Execution Plan - When a colleague showed this to me, a new world opened up showing how bad I could write a query and also how much more growth potential I had.
  • Set-based queries - Instead of thinking as a typical programmer as in do A, B, and then C (cursor, #table, @table).  I am still learning to think of sets within sets of columns and what it means to have a particular named column 'in scope'.  Creating nested queries are enjoyable because I have to think differently. (example: select imaginary.a, imaginary.b from ( select idname as 'a', idtext as 'b'  from monkey where likes = 'bananas' ) as imaginary)
  • Connection Pooling - The concept of a connection pool on each machine that tries to reuse connections (MSDN link) which helps feel it is ok to close connections immediately after use instead of holding on to them as long as possible.
  • Queryable Schema Info - This one is so simple that it shames me a little to admit that I never thought that system schema tables existed.  Coming from DB2/400 (before I knew about SQL and DDL) I did not need to care about the underlying storage.  So this one item also opened my mind. 

True story: I was reading about some of Brad Stone's RPG (link) tools and stumbled on the fact that the source code was stored as a member of a DDS table (essentially in a database).  DDS tables can contain multiple record format names, in this case folders when viewed using PDM.  I think I stewed on this for a couple of weeks dumbfounded that I could have missed something so obvious after the fact.

Thanks everyone that spoke at DevLink, looking forward to next year.


Posted on Friday, August 29, 2008 4:06 PM Nibbling at SQL | Back to top

Related Posts on Geeks With Blogs Matching Categories

Comments on this post: MSSQL Experts Duke it Out - Live

No comments posted yet.
Your comment:
 (will show your gravatar)

Copyright © rusty | Powered by: