Supress some serveroutput but not all
Posted on
16th Feb 2014 07:03 pm by
admin
Hi,
I have a script I'm working on that uses plsql to create and RMAN script, this uses dbms_output and also accepts user input as variables.
The script is working but there is some serveroutput I need to suppress and some not.
How can I do this?
Script is:
set serveroutput on format wrapped
set feedback off
set linesize 100
spool tom.out
declare
dbname varchar2(9) := upper('&dbname');
fs varchar2(12) := '&fs';
BEGIN
DBMS_OUTPUT.ENABLE(2000);
DBMS_OUTPUT.PUT_LINE(' DUPLICATE TARGET DATABASE TO '|| dbname ||';');
DBMS_OUTPUT.PUT_LINE(' '|| fs ||' ');
end;
/
spool off
set linesize 80
set feedback on
set serveroutput off
When I run the script I get:
SQL> @tom
Enter value for dbname: orcl4
old 3: dbname varchar2(9) := upper('&dbname');
new 3: dbname varchar2(9) := upper('orcl4');
Enter value for fs: /u10/oradata
old 4: fs varchar2(12) := '&fs';
new 4: fs varchar2(12) := '/u10/oradata';
DUPLICATE TARGET DATABASE TO ORCL4;
/u10/oradata
SQL> ! cat tom.out
Enter value for dbname: orcl4
old 3: dbname varchar2(9) := upper('&dbname');
new 3: dbname varchar2(9) := upper('orcl4');
Enter value for fs: /u10/oradata
old 4: fs varchar2(12) := '&fs';
new 4: fs varchar2(12) := '/u10/oradata';
DUPLICATE TARGET DATABASE TO ORCL4;
/u10/oradata
No comments posted yet
Your Answer:
Login to answer
193 38
Other forums
get multiple rows
Hi I want to get multiple rows from a db
I am using this for the db query
Code: public
Procedural to OOP
John Kleijn said that to avoid writing "crappy code", we should learn OOP and common OO pr
Passing Variables
What I'm wanting to do is when the user clicks on Arenas it will know the name of the country it's w
Sort a two dimensional array.
Hi. I've set up a two dimensional array that reads as follows:
Code: $modifiedData = array(
Call Screen statement Error
Dear Experts,
is there any setting that needs to be done before creating any dialog progr
captcha error
I have been trying to implement a captcha in php...
here is the code..
Code: (php) [Select
Needing Youtube thumb nail fix.
I have a script on a site that pulls in you-tube videos,
The problem is, that the thumb nails for
Stopped working!
So I had to change some stuff, none of it major. Stuff like the extension_dir and such. BEFORE I did
Help on query replacing the date
Hi Pals,
i want to replace the current date in a column to some value say C or D or any n
script is pulling more then they have....
I have this script for my game where they can change there race. This will cost them 2,500 points. H