Changing the SQL statement terminator

By default, the SQL and XQuery editor uses a semicolon ( ; ) as the default statement terminator. You can change the default statement terminator or specify a different statement terminator for the SQL statements in a script that you create in the SQL and XQuery editor.
Before you begin

If you want to change the statement terminator for all SQL statements, change the default statement terminator on the SQL and XQuery Editor page in the Preferences window (Window > Preferences).

A statement terminator applies to all of the SQL statements that are in the script in which you specify it. You can specify different statement terminators in different SQL scripts. The statement terminator can be a string of one or more case-sensitive characters. If you specify a string as the statement terminator, the statement terminator must be preceded by a space in your code.

The statement terminator that you specify for an SQL script persists every time that you open the script in the SQL and XQuery editor.

Prerequisite: The SQL script for which you want to change the statement terminator must be open in the SQL and XQuery editor.
About this task

To change the statement terminator for the SQL statements in an SQL script:

  1. Right-click in the SQL and XQuery editor, and then select Set Statement Terminator on the pop-up menu.
  2. In the Set Statement Terminator window, type one or more characters to use as the statement terminator and then click OK.
Results
If you specify a statement terminator other than the default, a comment is added to the top of the SQL script that indicates the statement terminator that you specified. Existing occurrences of the default statement terminator are not updated in the SQL script; you must change them manually.

Feedback