• I'm with Phil on this one. It was a good read and an interesting solution, but way more difficult than needed since SMO can do so much of the work.

    That said, yee hah! for so much discussion around getting database code into source control. I think this is a huge whole in lots of shops these days.

    "The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
    - Theodore Roosevelt

    Author of:
    SQL Server Execution Plans
    SQL Server Query Performance Tuning