Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Compiling pl/sql in sqlplus with an @ char within the code?

Re: Compiling pl/sql in sqlplus with an @ char within the code?

From: Maxim Demenko <mdemenko_at_arcor.de>
Date: Thu, 08 Jun 2006 15:49:56 +0200
Message-ID: <44882c60$0$4517$9b4e6d93@newsread2.arcor-online.net>


Jeremy schrieb:
> In article <44881e50$0$4496$9b4e6d93_at_newsread2.arcor-online.net>, Maxim
> Demenko says...

>> Jeremy schrieb:
>>> In article <448814db$0$11078$9b4e6d93_at_newsread4.arcor-online.net>, Maxim 
>>> Demenko says...
>>>> It seems, sqlplus gets broken on the first nonwhitespace "@" character ( 
>>>> regardless it is quoted).
>>>>
>>> I had also been wondering if there was a "set" statement I could use in 
>>> sqlplus to alter the defaults (e.g. the define is usually the & char)
>>>
>>> e.g. 
>>>
>>> SQL> set define {
>>> SQL> set runscript }
>>>
>>> (I made the second one up for illustrative purposes)
>>>
>> I don't quite understood your question,
>> clearly you can reassign the default '&' for substitution variables to 
>> another character or disable substitution behaviour at all (and after 
>> your script is run reenable it)

>
> Exactly - and I was wondering if there was a similar option for changing
> the @ character for something else. Or as you say disable at start of
> script and re-enable at end.
>
>> See 
>> http://download-east.oracle.com/docs/cd/B19306_01/server.102/b14357/ch12040.htm#sthref2736
>>

>
> cheers

I played a little bit with it and it seems, the escape can handle special meaning of "@" as well:

scott_at_ORA102> show escape
escape OFF
scott_at_ORA102> set escape on
scott_at_ORA102> begin

   2 dbms_output.put_line('Hello
   3 \@import
   4 World');
   5 end;
   6 /
Hello
@import
World

PL/SQL procedure successfully completed.

Best regards

Maxim Received on Thu Jun 08 2006 - 08:49:56 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US