Executing a SQL File

There are several ways to execute a SQL file.

To execute a SQL file from the context menu inside SQL Editor:

  1. Open a SQL file from the WorkSpace Navigator project folder in which it is stored.

  2. If the SQL file is not attached to a connection profile, select Attach Connection Profile from the context menu to attach to the associated database.

  3. Select Execute All. SQL Results view displays the result sets, database server messages, execution status (success or failure) and operation details.

To execute a SQL file from WorkSpace Navigator:

  1. Right-click the SQL file name and select Execute SQL File from the context menu. The SQL file executes, and results appear in SQL Results view.

To execute a SQL file from the toolbar:

  1. From WorkSpace Navigator, choose a SQL file from a project folder to execute.

  2. Press the "Choose an .sql File to Execute" button on the toolbar.

    The Choose a .sql File to Execute dialog appears.

  3. Select the SQL file you want to execute from the file system and click Open. The Select Profile for the Editor dialog opens.

  4. Choose the Database Connection Profile type and name.

    Note

    If you have not created a connection profile for ASA or ASE, click Create... , which launches the Create Connection Profile wizard.

  5. Click OK.

    Execution results appear in SQL Results view.

Opening a SQL File

Saving a Procedural Object Definition as a SQL File

Running a Procedural Object

Send your feedback on this help topic to Sybase Tech Pubs: pubs@sybase.com