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
unexpected T_VARIABLE error
Hey all! I'm getting an unexpected T_VARIABLE with the following function:
function getHighes
Is there a more efficient way to code this than what I have?
I have three associative arrays.
$combinedSettings
$userSettings
$defaultSettings
Help with Contact Form
I have this Form on an html page and the associated code on page.php (below).
I keep getting the
Is there a way to override built in php functions without APD?
I am trying to use the
rename_function()
override_function()
options that are built into
Turning Data into URLs?
This may seem very basic to you, but I'm having a hard time figuring out how to do this since I don'
foreach result into a single variable
Hi,
I have this code...
Code: [Select]foreach ($_POST['Interests'] as $interest =&
Sql and php order list script problems
Hi im having a few problems with trying to get the coding right on a orders list ive done (or trying
mysql query with single quotes in a variable
$sitedetails = "INSERT INTO vars (address, sitename, description, ownername, theme) VALUES ('$u
Form always sends to error page...
Hello,
Any help will be greatly appreciated. I am having trouble getting multiple fields to be re
using explode() to fill in checkboxes
Hi
I have a field stored in a table that contains regions in the UK separated by commas. Ther