Name

SET SQLBLANKLINES — Not available in iSQL*Plus

Synopsis

The SQLBLANKLINES setting, a new feature in Version 8.1 of SQL*Plus, allows SQL statements to contain embedded blank lines.

Syntax

SET SQLBLANKLINES {OFF | ON}

Parameters

OFF

Turns off this feature. This is the default setting and doesn't allow a SQL statement to have embedded blank lines.

ON

Turns on the feature and allows you to enter a SQL statement with an embedded blank line.

Examples

Pressing Enter on a blank line while typing a SQL statement into SQL*Plus normally signals the end of the statement. The statement is placed into the buffer, and you have the option of making further edits or of executing the statement. Turning SQLBLANKLINES ON allows you to put a blank line in the middle of your statement, as in the following example:

SQL> SET SQLBLANKLINES ON
SQL> SELECT
  2  *
  3
  4  FROM EMPLOYEE
  5
SQL>

This feature was added to SQL*Plus to allow it to execute Server Manager scripts, such as catproc.sql, without the need to go through and modify all the SQL statements in those scripts. Unlike SQL*Plus, the now defunct Server Manager utility allowed blank lines in a SQL statement.

Get Oracle SQL*Plus: The Definitive Guide, 2nd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.