Prompt Command With Ending ''-'' (Dashes) Treated As Continuation Character

(Doc ID 461068.1)

Last updated on OCTOBER 10, 2007

Applies to:

SQL*Plus - Version: to
This problem can occur on any platform.


In SQL*Plus, the PROMPT command is not handled in the manner one would normally expect if the last character on the line is a dash/hyphen (-).  It treats the dash/hyphen (-) as a continuation character when that is not the intent.

Example 1:
For example, from a SQL script the below:

prompt Some Text
prompt ---------

produces the following output:

Some Text
-------- prompt

The output intended is:

Some Text
<blank line>

Example 2:

From the command prompt, the following is seen:

SQL> prompt abc
SQL> prompt ---

Instead of:

SQL> prompt abc
SQL> prompt ---


Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms