connect from perl: error in Carp.pm - Mailing list pgsql-novice

From Marc Mamin
Subject connect from perl: error in Carp.pm
Date
Msg-id 1912.1114700027@www10.gmx.net
Whole thread Raw
Responses Re: connect from perl: error in Carp.pm
List pgsql-novice
Hello,


When I try to connect as following, I get an error in Carp.pm:

use DBI;

# connecting to database

my $username = 'marc';
my $password = 'marc';

$dbh = DBI->connect("DBI:Pg:dbname=my_db", $username, $password,{AutoCommit
=> 1, RaiseError => }) || die "Unable to connect to database $DBI::errstr";


 => Not a CODE reference at /usr/lib/perl5/5.8.3/Carp.pm line 178.

Any idea what this error means?

Maybe there are some right issue; I installed DBI and DBD as root, I'm
calling the script as root, but postgres runs under its own user.

cpan>  install DBI
cpan>  install DBD::pg

Thanks,

Marc

--
+++ Sparen beginnt mit GMX DSL: http://www.gmx.net/de/go/dsl

pgsql-novice by date:

Previous
From: Michael Fuhr
Date:
Subject: Re: function in a view
Next
From: "Richard Lynch"
Date:
Subject: Re: [PHP] temp tables