more problems with transactions - Mailing list pgsql-general

From Campbell, Scott
Subject more problems with transactions
Date
Msg-id ED7A447524CCD311A9BF009027DC86ED011E39FE@NSEXCH02
Whole thread Raw
List pgsql-general
Hey again....

I have another question regarding using transactions with perl/dbi.

I think I have the general idea of creating and committing the transactions
etc through the DBI under control but,
My problem is that I'm connecting to the database in one perl script which
opens the transaction, and then calling the same script recursivly aswell as
another script later on which will eventually commit the transaction. Each
time the script is re-called, the connection is boaken to the database (I
read why this happens in the DBI man page and I'm cool on the fact that when
you execute a new script, the resources from the old one are released).

to try to get around this, I tried passing the database handle back to the
script to keep the connection and my transaction alive but when I try to
execute a query I get an error.

so my main question is, how do I keep my database connection/transaction
alive while going from script to script?
any ideas???

Thanks again :)
Scott



pgsql-general by date:

Previous
From: "Joel Burton"
Date:
Subject: Re: convert from access
Next
From: Chris
Date:
Subject: Re: INHERITANCE