Perl-Postgres connection: 'Commit' method not found in DBI. Advice?



I am working with a perl file intended to enter a postgresql database (as user postgres), select a list of key values based on one of those values and delete any records which match the returned results. The purpose of the program is to delete inactive records from the database that are over two years in age.

(For the record, the system in question is running SuSE 9.3 os, Apache2, Postgres 8.1.3, and appears to be running Perl 5.8.6)

When I first ran the perl script, it did not appear to be working; entering the database afterwards would show that the data was still present. After finding and uncommenting a 'commit' statement at the end, I am now ending up with the error message

Can't locate object method "commit" via package "DBI::st" at ./purge_acnt line
242 (#1)
(F) You called a method correctly, and it correctly indicated a package
functioning as a class, but that package doesn't define that particular
method, nor does any of its base classes. See perlobj.
Uncaught exception from user code:
Can't locate object method "commit" via package "DBI::st" at ./purge_acnt line 242.
at ./purge_acnt line 242
Database handle destroyed without explicit disconnect at ./purge_acnt line 242.
Database handle destroyed without explicit disconnect at ./purge_acnt line 242.

I am asuming that the last two lines are because the program crashed, artificially severing the connections to the DB. (The last couple of lines of the program are normal disconnect statements, but occur after the 'commit' line that triggered the error.) It's the rest of the error that I am confused about. If I am reading it correctly, it seems to be saying that there is no 'commit' function in the DBI. Do I need to update my DBI files somehow, or is there another way to prevent this error from occuring? And if I have to update, would someone please be kind enough to link me to a good set of instructions on doing so?

Thank you for your consideration.


---------------------------------
Sucker-punch spam with award-winning protection.
Try the free Yahoo! Mail Beta.

Relevant Pages

  • Re: Perl-Postgres connection: Commit method not found in DBI. Advice?
    ... When I first ran the perl script, it did not appear to be working; entering the database afterwards would show that the data was still present. ... After finding and uncommenting a 'commit' statement at the end, I am now ending up with the error message ... and it correctly indicated a package ... Database handle destroyed without explicit disconnect at ./purge_acnt line 242. ...
    (perl.dbi.users)
  • Re: [Full-Disclosure] [SHATTER Team Security Alert] Multiple vulnerabilities in Oracle Database Serv
    ... Multiple vulnerabilities in Oracle Database Server ... > and Esteban Martinez Fayo of Application Security, ... > DBMS_REPCAT package ...
    (Full-Disclosure)
  • Re: perl MySQL using DBI - security issue
    ... Not sure if it's the best way, but the way I do it is to have that data stored in a config file that is owned by a dummy user and only readable by that user. ... All programs that need the database then have to be setuid that dummy user and then use the database package, 'drop' privs and then exit if privs can be regained. ... Allowing people to use these your DB-based code as libraries now requires you to vett the code since your users can't setuid their scripts to the dummy user. ...
    (comp.lang.perl.misc)
  • SSIS Error: transport-level error...
    ... Fellow SSIS Users: ... Backup a database. ... The point is that when the package gets to step 5 (after step ... It sounds like a connection error. ...
    (microsoft.public.sqlserver.dts)
  • Re: DPS Initial Ideas
    ... database will help with the parallelization of package building? ... the ports collection and package ... upgrade this package". ... by maintaining its own parallel version of the metadata in a database ...
    (freebsd-hackers)