SQL Job Scripter
SQL Job Scripter is a command line utility that produces scripts of SQL Agent jobs. It will script either to a single file or to one file per job.

The sqljobscripter utility scripts out SQL Agent jobs into individual files suitable for source control

-S <servername>
-1
switch parameter description
-S server_name server name to connect to
-d directory output directory use double quotes if there are any spaces
-p prefixofjob prefix of the job name to select ex: "DBA_"
-1 one_file put the output into just one file
-m many_files put the output into many files



Example:
sqljobscripter -S (local) -p DBA_ -m -1 d "c:\source control\server1\jobs"

The defaults for server, directory and prefix are also in the sqljobscripter.exe.config file.

Last edited Oct 7, 2012 at 2:57 PM by AndrewNovick, version 2