On Tue, Feb 24, 2004 at 03:53:30PM -0500, Jeff Urlwin wrote: > > > > I am using DBD::Pg, and I noticed that after a statement > > causes an error, subsequent statements (until rollback) fail > > with "current transaction is aborted, queries ignored until > > end of transaction". > > I'm probably oversimplifying, but if the first execute fails, you can > rollback and run the second one, since the first one fails anyway, there's > nothing really outstanding to do. Unless, you want to do this in a larger > loop and the larger loop needs to be in a single transaction.
Yes, that's what I meant about doing it within one transaction. In my application, I cannot be sure that no important work was done earlier in the same transaction, so it wouldn't be right to open a new transaction and continue. I could try to redesign the application around this need, but I would rather just set the disabled flag. Real deletion can be attempted in the background if needed. Andrew