My Oracle Support Banner

Hyphen at the End of the Line in SQL Statement gives Error ORA-00923 (Doc ID 292331.1)

Last updated on MAY 30, 2023

Applies to:

SQL*Plus - Version to [Release Oracle10g to 11.2]
Information in this document applies to any platform.
This problem can occur on any platform.


Running a SQL statement with minus sign/hyphen (-) at the end line gives error:

SQL> select 5 -
> 7 from dual;

select 5 7 from dual
ERROR at line 1:
ORA-00923: FROM keyword not found where expected


To view full details, sign in with your My Oracle Support account.

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

In this Document

My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.