Newbie Question: (no error string)

From: Elijah O. Alcantara (elijah_at_asti.dost.gov.ph)
Date: 06/18/04


To: dbi-users@perl.org
Date: Fri, 18 Jun 2004 14:04:23 +0800

I don't get it, I followed the DBI examples from
http://www.saturn5.com/%7Ejwb/dbi-examples.html and got this error:

$ perl testing.pl

DBI connect('GovPH2','postgres',...) failed: (no error string) at
testing.pl line 7
Database Connection failed!!!: ERROR: Missing '=' after 'GovPH2' in
conninfo at testing.pl line 7.

Here's the short code:
-----
#!/usr/bin/perl

use strict;
use warnings;
use DBI;

my $dbh = DBI->connect('DBI:Pg:GovPH2',
                       'username',
                       'password',
                      ) || die "Database Connection failed!!!:
$DBI::errstr";

$dbh->disconnect();
------



Relevant Pages

  • Re: use of DBI; I am getting multiple error messages mixed in with the correct output.
    ... expected a mature library like DBI to behave like this. ... it is the most DWIM way of representing NULL values in perl. ... behaviours that would be familiar to a SQL programmer. ... warnings enabled (warnings are output to STDERR, ...
    (comp.lang.perl.misc)
  • Re: use of end
    ... and the DBI. ... use strict; ... use warnings; ... cowens@amans:~$ perl t.pl ...
    (perl.beginners)
  • Problem of DBI build
    ... I installed Oracle Application Server 4.0.8.2 included perl module. ... I need to installe DBI and DBD::Oracle module. ... You can install them any time after installing the DBI. ... line 318: error 1705: Function prototypes are an ANSI feature. ...
    (perl.dbi.users)
  • Problem of DBI build
    ... I installed Oracle Application Server 4.0.8.2 included perl module. ... I need to installe DBI and DBD::Oracle module. ... You can install them any time after installing the DBI. ... line 318: error 1705: Function prototypes are an ANSI feature. ...
    (perl.dbi.users)
  • Re: use of DBI; I am getting multiple error messages mixed in with the correct output.
    ... T> expected a mature library like DBI to behave like this. ... I learned plenty about the perl side of things from her posts. ... closely represent the SQL idea of a null. ... trivially easy to perform bulk loads using the DB's particular ...
    (comp.lang.perl.misc)