Thread: perl problems

perl problems

From
"Dax Duskin"
Date:
Hello,

I've been having problems getting queries from perl to run with Pg.pm.  My
database connection works and the database is opened fine.  However when I
execute a query like "$result = $conn->exec($query);" I can never return any
tuples.  I have tried many different forms of the sql query, (the exact same
queries work fine in psql) on a couple databases and tables.  Still no luck.
The code worked last night.  Is there some setting on postmaster that I need to
set?  What happened?

Thanks,
Dax Duskin



RE: perl problems

From
"Chuck Kimber"
Date:
I don't know what happened, but as I understand it Pg.pm hasn't been
maintained for some time now... since DBI came out.  I would recommend using
DBI with DBD::Pg to query your postgres databases.  It also makes it easy if
ever have to migrate to a new DB server, God Forbid. You just download the
new DBD driver and change your connection setup and BAM!  All your queries
and accompanied code still run without modification.

-Chuck

-----Original Message-----
From: pgsql-novice-owner@postgresql.org
[mailto:pgsql-novice-owner@postgresql.org]On Behalf Of Dax Duskin
Sent: Thursday, March 15, 2001 7:52 AM
To: pgsql-novice@postgresql.org
Subject: [NOVICE] perl problems


Hello,

I've been having problems getting queries from perl to run with Pg.pm.  My
database connection works and the database is opened fine.  However when I
execute a query like "$result = $conn->exec($query);" I can never return any
tuples.  I have tried many different forms of the sql query, (the exact same
queries work fine in psql) on a couple databases and tables.  Still no luck.
The code worked last night.  Is there some setting on postmaster that I need
to
set?  What happened?

Thanks,
Dax Duskin



---------------------------(end of broadcast)---------------------------
TIP 6: Have you searched our list archives?

http://www.postgresql.org/search.mpl