Andrew Sullivan <[EMAIL PROTECTED]> writes:

> On Thu, Apr 14, 2005 at 07:21:38PM +0200, Andreas Joseph Krogh wrote:
> > 
> > So, what you're suggesting is that a restart of the webapp should make 
> > vacuum 
> > able to delete those dead rows?
> 
> Yes, but that'll only solve your problem for now.  You'll have the
> problem again soon.  What's keeping open the transaction?

This is presumably because of the long-standing issue that Postgres takes the
snapshot as soon as the BEGIN is issued. A lot of drivers issue a "COMMIT;
BEGIN;" right away even though it could be a long time before any actual work
is done.

Other databases (by which I mean Oracle) treat BEGIN as a noop. The snapshot
starts when the first SQL statement that needs a snapshot is executed. So
until a SELECT is issued the connection doesn't participate in any
transactional issues like keeping old versions of records around.

-- 
greg


---------------------------(end of broadcast)---------------------------
TIP 8: explain analyze is your friend

Reply via email to