Backup a single SQL Agent Job

  1. Start SQL Server Management Studio.
  2. Expand the SQL Server Agent folder, and then expand the list of Jobs.
  3. Right-click the job you want to create a backup script for, and then select Script Job as.
  4. Click CREATE To or DROP To, then click New Query Editor WindowFile, or Clipboard to select a destination for the script. Typically, the destination is a file with a .sql extension.
  5. Repeat this procedure from Step 3 for each job you want to script.

Backup multiple SQL Agent Jobs

  1. Start SQL Server Management Studio.
  2. Expand the SQL Server Agent folder, and then expand the list of Jobs.
  3. Click to the View menu panel, then to Object Explorer Details (or press F7) to show the details window (see image below).
  4. The new details window should show a list of jobs which allows to select multiple jobs.
  5. Use Shift+Left-Click or CTRL+Left-Click to select the jobs to create a backup script for, then right-click on them and select Script Job as.
  6. Click CREATE To or DROP To, then click New Query Editor WindowFile, or Clipboard to select a destination for the script that will contain all the job you want to backup. Typically, the destination is a file with a .sql extension.

Restore one or multiple SQL Agent Job

  • Start SQL Server Management Studio.
  • Click File, click Open, then click File.
  • Locate and open the file containing the scripted job(s).
  • Execute the script to create the job(s).