Re: How to disable '@' in SQL*Plus? Thanks Daniel for the reply.
Do you mean that it is impossible to disable this behaviour?
As far as I know, the DB does not interpert the '@' specially in this
case. It is SQLPlus which treat it as a special command. And surely
Oracle will allow a reserved word in a string.
(I would think that the '@' was considered reserved word because of
its use in db link. But not sure...)
BTW, I don't think having a '@' in a the start position of a line in
multi-line string indicates a bad design...
Actually, similar problem also arise for the following case:
(test.sql)
create or replace PACKAGE MyPackage IS
PROCEDURE MyProcedure(MyParam1 IN VARCHAR2) ;
/*
Do something.
@param MyParam1 First Parameter
*/
END MyPackage;
/
(In SQL*Plus)
SQL> @C:\test.txt
SP2-0310: unable to open file "param.sql"
Package created.
(I would agree that there may be an issue on programming style here.)
Daniel Morgan <damorgan@x.washington.edu> wrote in message news:<1075354681.632738@yasure>...
> SELECT keyword
> FROM v$reserved_words
> WHERE LENGTH(keyword) = 1;
>
> Don't try to kludge your way around a bad design ... fix your design. |