On Fri, 3 Jan 2003 07:41:02 -0500, <[EMAIL PROTECTED]> wrote:
> I have a script that loads large (40 Meg files) into a postgres database.
> I would like to issue a vacuum and analyze, but I get the message "VACUUM
> cannot run inside a BEGIN/END block" when I try to send the message.
> Autoconfirm is off, an the vacuum statement comes right after a commit.

You need to turn AutoCommit back on to do a vacuum. DBD::Pg starts a
new transaction whenever you turn AutoCommit off, and after every
commit and rollback, since this is much simpler than doing it only when
actually needed.

If you have more work to do after vacuuming, just turn AutoCommit off again.

-- 
        Peter Haworth   [EMAIL PROTECTED]
"Their fundamental design flaws are completely hidden by their
 superficial design flaws."
  -- Douglas Adams on Microsof, er, the Sirius Cybernetics Corporation

Reply via email to