Is there something wrong with Perl's dbi and PostgreSQL? - Mailing list pgsql-sql

From Jeff Self
Subject Is there something wrong with Perl's dbi and PostgreSQL?
Date
Msg-id 1064857916.27970.18.camel@jselfpc
Whole thread Raw
Responses Re: Is there something wrong with Perl`s dbi and PostgreSQL?  (greg@turnstep.com)
List pgsql-sql
I just tried running a perl script that I wrote about a year ago. It had
worked for me in the past. Now it doesn't work. I can view data from a
table, but I am unable to either drop a table or create a table. I'm
running PostgreSQL 7.3.4 and DBI 1.35 along with Perl 5.8.1.

Here's my script for creating a table:
#!/usr/bin/perl -w
# createfoo.pl

use strict;
use DBI;

my $dbh = DBI->connect( 'dbi:Pg:dbname=test','dbuser','password',                     {
RaiseError=> 1,                       AutoCommit => 0                     }                     ) || die "Database
connectionnot made:
 
$DBI::errstr";

my $query = $dbh->prepare(           "CREATE TABLE foo (foo_id INT4," .           "foo_name TEXT)"           );
$query->execute();
$dbh->disconnect();


Has anything changed to DBI? I haven't found anything on google
suggesting that it has.

-- 
Jeff Self
Dept. of Information Technology
City of Newport News
(757)926-3741



pgsql-sql by date:

Previous
From: Stephan Szabo
Date:
Subject: Re: SRF Functions don't want to return empty tuple
Next
From: Bruce Momjian
Date:
Subject: Re: does postgresql execute unions in parallel?