Export (0) Print
Expand All
Expand Minimize
5 out of 11 rated this helpful - Rate this topic

How to: Script Jobs Using Transact-SQL (SQL Server Management Studio)

This topic explains how to create Transact-SQL scripts that perform job steps.

To script jobs using Transact-SQL

  1. In Object Explorer, connect to an instance of the Microsoft SQL Server Database Engine, and then expand that instance.

  2. Expand SQL Server Agent, expand Jobs, right-click the job you want to script.

  3. From the right-click menu, select Script Job as, then CREATE To or DROP To and click one of the following:

    • New Query Editor Window, which opens a new Query Editor window and writes the Transact-SQL script to it.

    • File, which saves the Transact-SQL script to a file.

    • Clipboard, which saves the Transact-SQL script to the Clipboard.

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.