Hi all,
Just wanted to thank everyone who helped shed light for
me. It worked out great in my test program below so I will add it to my
production program now. Thanks a bunch.
#!/usr/bin/perl
use DBI;
$ENVR = cwd() =~
/devl/ ? "devl" : "prod";
require
"/usr/local/apps/sma/${ENVR}/bin/Local_Vars.pl" || die "$!\n";
my $dbh =
DBI->connect("dbi:Oracle:$INSTANCE","$DBUSER","$DBPASS",
{
PrintError => 1, RaiseError => 1 }); $dbh->func(1000000,
'dbms_output_enable');
my $sth =
$dbh->prepare("DECLARE tmp
VARCHAR2(50);
BEGIN SELECT SYSDATE INTO tmp FROM DUAL; DBMS_OUTPUT.PUT_LINE('The date is '|| tmp); DBMS_OUTPUT.PUT_LINE('This is the second line.'); DBMS_OUTPUT.PUT_LINE('This is the third line.'); DBMS_OUTPUT.PUT_LINE('This is the fourth line.'); END;");
$sth->execute();
$sth->finish; foreach ($dbh->func('dbms_output_get')) {
print "$_\n"; } $dbh->disconnect();
exit;
-----Original Message-----
From: Loo, Peter # PHX [mailto:[EMAIL PROTECTED]] Sent: Tuesday, February 20, 2001 1:02 PM To: [EMAIL PROTECTED] Subject: SET SERVEROUTPUT ON Hi
All,
I want to
set this environment on so that anything that the store procedure spits out will
show during the debug process within Perl DBI connection. Can someone
please show me how I can set this?
$dbh->do("SET SERVEROUTPUT ON");
Not
working. Please help.
Peter
|
- SET SERVEROUTPUT ON Loo, Peter # PHX
- Re: SET SERVEROUTPUT ON Michael A. Chase
- RE: SET SERVEROUTPUT ON Mitchell, Louise M
- Re: set serveroutput on Loo, Peter # PHX
- Re: set serveroutput on Michael A Chase
- Re: set serveroutput on Ravi Kongara
- RE: set serveroutput on Fox, Michael