SqlPlus SP2-0734: Error
By default SQL*Plus doesn't like blank lines. However we can easily configure our SQL*Plus environment to ignore them:
SQL> set sqlblanklines on
We can also put the setting in our glogin.sql file (assuming we're allowed to edit it, which isn't always the case).
Note that this parameter doesn't work in ancient versions of the client.
How to resolve SP2-0734 in SQL Plus using CONCAT?
Add this to your SQL*Plus prompts. (SET HEAD OFF
)
SET TERMOUT OFF;
SET VERIFY OFF;
SET SQLBLANKLINES ON;
SET HEAD OFF /* This turns of the headers in result */
SET FEEDBACK OFF /* Turns off the result feedback */
Issue is the result column of your SELECT
had the default name starting with CONCAT(..
as alias.
So it is like..
CONCAT('INSERTINTOTAR_TEMP_PRICE(PRODUCT_ID,START_DATE,LIST_PRICE,MIN_PRICE,END_DATE)VALUES(',P.PRODUCT_ID||','''||PR.START_DATE||''','||PR.LIST_PRICE
------------------------------------------------------------------------------------------------------------------------------------------------------
And as you execute your INSERT
script, even tht gets executed along with your other inserts. So, we have to turn off the headers.
SP2-0734: unknown command beginning select
The space before select
makes me think it's a character encoding issue. See e.g. this, this
beginning " select..."
I'm not familiar enough with powershell to know what the problem is. I can think of a workaround, but it's a bit of a hack.
$chekdbsql = "`nselect status from v`$instance;"
This makes sure that whatever garbage characters are getting inserted at the beginning of the string will be on their own line in SQL*Plus. So if you get a SP2-0734, your select command will still run after that. Since it's now a double-quoted string, I escaped the $
.
SP2-0734: unknown command beginning lsnrctl st... - rest of line ignored. error-17002
LSNRCTL
is a command line-tool not a command on SQL*PLUS
.
Try
lsnrctl start listenername
on terminal OR SQL> !lsnrctl status
on Linux and SQL> host lsnrctl status listenername
on Windows.
Oracle Pl/SQL trigger compilation error via SQL*PLUS
in its default setting SQL*Plus won't deal properly with blank lines, you need to issue the following command:
SQL> SET SQLBLANKLINES on
See this other SO.
Update: I answered too fast, the blank line doesn't seem to be the problem here. I tried your code on my database and the issue seems to come from the FORCE
keyword. The 10gR2 documentation doesn't mention this keyword. The trigger compiles when you remove it.
Related Topics
Full-Text Search SQL Server 2005
How to Parse JSON in Oracle SQL? (Version:11.2.0)
How to Pass a Parameter from Vb.Net
How to Enforce Set-Like Uniqueness Between Multiple Columns
Remove Duplicate Records Except the First Record in SQL
Why Would Year Fail with a Conversion Error from a Date
Convert Unknown Number of Comma Separated Varchars Within 1 Column into Multiple Columns
How to Convert Spark Schemardd into Rdd of My Case Class
Syntax Error in Dynamic SQL in Pl/Pgsql Function
Join One Row to Multiple Rows in Another Table
In Ms SQL Server, How to "Atomically" Increment a Column Being Used as a Counter
How to Get a Hash of an Entire Table in Postgresql