I recently came across a way to script up all agent jobs in one go within SQL Server Management Studio (SSMS). Previously I used to right
click on each job and select ‘Script Job as’ to script up each one individually, but this can be very labourious
if there are a lot of jobs to do.
To script all jobs, just open the ‘Object Explorer Details’ from the View menu in SSMS, or press the F7 key. Click on
any job in the Object Explorer window and a list of all the agent jobs appears in the ‘Object Explorer Details’ window.
Select all the jobs you want to script (press the Ctrl button while clicking to select individual jobs) and then
right click and select the scripting option you want. This will then create all the selected jobs as a single query. You can script to a query window, file etc.