Skip site navigation (1) Skip section navigation (2)

connect from perl: error in Carp.pm

From: "Marc Mamin" <m(dot)mamin(at)gmx(dot)net>
To: pgsql-novice(at)postgresql(dot)org
Subject: connect from perl: error in Carp.pm
Date: 2005-04-28 14:53:47
Message-ID: 1912.1114700027@www10.gmx.net (view raw or flat)
Thread:
Lists: 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

Responses

pgsql-novice by date

Next:From: BobDate: 2005-04-28 14:55:24
Subject: Re: temp tables
Previous:From: Schuhmacher, BretDate: 2005-04-28 14:01:42
Subject: Re: temp tables

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group