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

SQL Anywhere 11.0.1 (Français) » SQL Anywhere Server - Database Administration » Administering Your Database » Database administration utilities


Script Execution utility (dbrunsql)

Allows you to execute SQL commands and run command files against databases running on Windows Mobile.

dbrunsql [ options ] [ SQL-script-file | SQL-command ]
Option Description
-c "keyword=value; ..." Specify connection parameters. See Connection parameters.
-d Write data exported from result sets to the output file. If you do not specify -d, then all dbrunsql output is written to the output file.
-e [ c | p | s ]

Control the behavior when an error is encountered while executing statements. By default, dbrunsql prompts the user when an error occurs.

  • c   Ignore the error and continue executing statements.

  • p   Prompt the user to see if the user wants to continue.

  • s   Stop executing statements.

-f [ f | a ]

Specifies the data format dbrunsql uses to export result sets. You can specify one of the following values:

  • a   Use ASCII format when exporting data.

  • f   Use FIXED format when exporting data. This is the default format.

-g [ + | - ] Prevent the GUI from appearing. By default, the dbrunsql GUI appears.
-o filename Writes output messages to the named file.

Suppress output messages. This is useful only if you start Interactive SQL with a command or command file. Specifying this option does not suppress error messages, but it does suppress the following:

  • warnings and other non-fatal messages
  • the printing of result sets
-qc Close the dbrunsql window once the command or script file has been executed.
-s number Specify the maximum number of bytes fetched per column when you are exporting result sets using the FIXED format. The default value is 255.
-v Include all lines of each SQL statement in the dbrunsql output. Otherwise, when you execute a script file, the number of the line that is currently being executed appears.

The dbrunsql utility allows you to execute SQL commands or run command files against a database. The SQL Anywhere Script Execution utility (dbrunsql) is only supported on Windows Mobile.