RE: SQLPLUS format question

  • From: "Hand, Michael T" <HANDM@xxxxxxxxxxxx>
  • To: "Oracle L \(E-mail\)" <oracle-l@xxxxxxxxxxxxx>
  • Date: Tue, 15 Aug 2006 11:01:23 -0400

The next best thing when spooling SQL commands is to change the SQL
prompt 
to a remark: sqlp 'REM ' or '-- '.  For multi-line SQL set sqlcont '-- '
.  Effective as
far back as I can remember.
 
As in:
 
SQL> set sqlp 'REM ' sqlcont '-- ' heading off feedback off
REM 
REM spool test.sql
REM select 'This is my dynamic SQL;' -
-- from dual;
 
This is my dynamic SQL;
REM spool off
REM set sqlp 'SQL> '
. . .
$ cat test.sql
REM select 'This is my dynamic SQL;' -
-- from dual;
 
This is my dynamic SQL;

REM spool off
$
 
Regards,
Mike Hand
 


________________________________

        From: oracle-l-bounce@xxxxxxxxxxxxx
[mailto:oracle-l-bounce@xxxxxxxxxxxxx] On Behalf Of Jared Still
        Sent: Monday, August 14, 2006 7:38 PM
        

        Mea Culpa:  I had assumed it was being run from a file...
        
        -- 
        Jared Still
        Certifiable Oracle DBA and Part Time Perl Evangelist
        


-- 
This transmission is intended only for use by the addressee(s) named herein and 
may contain information that is proprietary, confidential and/or legally 
privileged. If you are not the intended recipient, you are hereby notified that 
any disclosure, copying, distribution, or use of the information contained 
herein (including any reliance thereon) is STRICTLY PROHIBITED. If you received 
this transmission in error, please immediately contact the sender and destroy 
the material in its entirety, whether in electronic or hard copy format. Thank 
you.


Other related posts: