If you use SMO to create a script procedure for a stored procedure, you get a script that you can't use. It looks something like this:set ansi_nulls onset quoted_identifier oncreate procedure [mySchema].[myProcedure]... etc ...But of course, you can't actually RUN this script, because you'll get the errorMsg 111, Level 15, State 1, Procedure Test_Proc, Line 7'CREATE/ALTER PROCEDURE' must be the first statement in a query batch.Setting the NoCommandTerminator property to False doesn't help. (Why am I forced to figure out a double negative? Why wasn't this called IncludeCommandTerminator? AAArgh!!!)I would like an option that tells the generated script to leave out the setting of Ansi_Nulls and Quoted_Identifier entirely.Um, I don't know what category this is. I'll set it to Engine. If that's not right, PLEASE re-route it.P.S. SQL 2005 and 2008 both have this problem.
Version
Category
Operating System
Platform