Deploying routines to a database

Use the Deploy a Routine wizard to deploy exported stored procedures or user-defined functions to a database. The target database must be the same type as the database that the object was created for. You normally deploy routines that you exported using the Export a Routine wizard.

Prerequisite: Before you deploy a routine, first export it to a script.

The instructions in this topic apply to routines that were exported to a project Scripts folder. If you exported a routine to the file system, follow the instructions in the file called DeployInstructions.txt that was generated with the export script into the file folder that you specified in the Export a Routine wizard.

To deploy a routine to a database:

  1. Switch to the Data perspective.

  2. In the Data Definition view, right-click a routine export script in the Scripts folder, and click Deploy from the pop-up menu. The export script is either an SQL file or an XML file, depending on the routine type and target database. A wizard opens.

  3. Complete the steps of the wizard.

The routine is deployed to the target database.