• george sibbald

    Yeah an agent job could have worked, oh well it only took me a couple of hours to write the SMO code.

    Having said that though the SMO solution is less than 40 lines long and that includes error handling, comments and a lot of whitespace 🙂

    Carlo Mitchell

    Yeah I could do that, but BCP was the peice that was failing. The SQL I was running was returning the procedure correctly so there was no need to replicate something that SQL Server already does. I'm also not a fan of storing them that way as all it takes is the trigger to fail once at a critical time and the table is one step behind what the database has as the latest procedure or worse it's mangled.