Error.pm and DBI.pm problem
From: Horst Walter (unkwb_at_web.de)
Date: 10/05/04
- Next message: .rhavin: "finding the last element in a referenced array"
- Previous message: Randal L. Schwartz: "Re: Which Counter is Perfect?"
- Next in thread: Rhesa Rozendaal: "Re: Error.pm and DBI.pm problem"
- Reply: Rhesa Rozendaal: "Re: Error.pm and DBI.pm problem"
- Reply: Anno Siegel: "Re: Error.pm and DBI.pm problem"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: 5 Oct 2004 08:28:43 -0700
As a newbie to Perl I run into the following problem. With this I get
the following problem with the code below:
Can't call method "with" without a package or object reference at
autodb.pm line 163
I have tried "use Error qw(:try);" and "use Error". I am confused
since this try/catch block works in other parts of my code pretty
fine. It seems to have something to do with DBI.
Any hints would be appreciated.
Thanks!
try {
my ($dbh) = @_;
unless ($dbh->disconnect) {
die("autodb::oracleLogoff $DBI::errstr");
};
}
catch Error with {
my $err = shift;
print "autodb::oracleLogoff(..) $err";
};
- Next message: .rhavin: "finding the last element in a referenced array"
- Previous message: Randal L. Schwartz: "Re: Which Counter is Perfect?"
- Next in thread: Rhesa Rozendaal: "Re: Error.pm and DBI.pm problem"
- Reply: Rhesa Rozendaal: "Re: Error.pm and DBI.pm problem"
- Reply: Anno Siegel: "Re: Error.pm and DBI.pm problem"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|