Re: RE: Re: RE: Toad v11 - execute snippet at cursor doesn't like /

Boneist <[email protected]>
Newsgroups gmane.comp.db.oracle.toad.free
Message-ID <32335886.158531318610831750.JavaMail.SYSTEM@alvqcfw02>
 Message from: Boneist 

Great - thanks!

_______________________________________

Historical Messages 


Author: Boneist
Date: Fri Oct 14 09:46:41 PDT 2011
Great - thanks!
__

Author: Michael Staszewski
Date: Fri Oct 14 08:25:46 PDT 2011




 

Fixed for next beta.

Michael


__

Author: Boneist
Date: Fri Oct 14 06:31:11 PDT 2011
I doubt it&#39;s that - the code runs fine in v11 if I strip off the /

Having looked into it further, it seems that if I have the block of code starting on line 1 of the editor, it complains about the / whereas if I press return to take the start of it to line 2, it&#39;s fine.

Have reproduced with:

 begin   null;
end; /

 If the begin is on line&nbsp;1 of the editor, it fails with the PLS-00103 error, if it&#39;s on line 2, then it runs without erroring.

Weird!

ETA: If I highlight the block (including the /) and then execute snippet, it works, even if it starts on line 1.  'BEGIN my_proc; NULL; END;'


__

Author: Boneist
Date: Fri Oct 14 03:26:40 PDT 2011
In Toad v10.6, the following would run quite happily when executed via &quot;Execute SQL snippet at cursor (Ctrl+Enter)&quot;:

 DECLARE X   NUMBER ;   BEGIN SYS . DBMS_JOB.SUBMIT (   job   =&gt;   X   , what   =&gt;   &#39;BEGIN my_proc; END;&#39; , next_date   =&gt;   to_date( &#39;13/10/2011 10:48:48&#39; , &#39;dd/mm/yyyy hh24:mi:ss&#39; ) ,interval   =&gt;   &#39;trunc(sysdate+1) + 5/24&#39; , no_parse   =&gt;   FALSE ); SYS . DBMS_OUTPUT.PUT_LINE ( &#39;Job Number is: &#39;  ||  to_char( x ));   COMMIT; END; /

However, when I run the same thing in Toad v11 and execute the snippet, I get the following error:

[Error] Execution (14: 1): ORA-06550: line 14, column 1:
PLS-00103: Encountered the symbol &quot;/&quot; The symbol &quot;/&quot; was ignored.


Was this deliberately changed to not accept the &#39;/&#39; on the end of the pl/sql block? Could it be changed/fixed so that it works with and without the &#39;/&#39; please?
__
_______________________________________
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.