Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 10.0.1 » SQL Anywhere Server - SQL Usage » Importing and Exporting Data

Using the sa_migrate stored procedures Next Page

Using SQL command files


This section describes how to process files consisting of a set of commands. Command files are text files that contain SQL statements, and are useful if you want to run the same SQL statements repeatedly.

Creating command files

You can use any text editor that you like to create command files. You can include comment lines along with the SQL statements to be executed. Command files are also commonly called scripts.

Opening SQL command files in Interactive SQL

On Windows platforms you can make Interactive SQL the default editor for .sql files. Thus, you can double-click the file so that its contents appears in the SQL Statements pane of Interactive SQL.

For more information about making Interactive SQL the default editor for .sql files, see Options dialog: General tab.

Executing SQL command files

You can execute command files in any of the following ways:


Running SQL command files
Writing database output to a file