Re: autocommit vs TRUNCATE et al - Mailing list pgsql-hackers

From Bruce Momjian
Subject Re: autocommit vs TRUNCATE et al
Date
Msg-id 200210190215.g9J2FWZ11631@candle.pha.pa.us
Whole thread Raw
In response to Re: autocommit vs TRUNCATE et al  (Mike Mascari <mascarm@mascari.com>)
List pgsql-hackers
Mike Mascari wrote:
> Gavin Sherry wrote:
> > On Fri, 18 Oct 2002, Tom Lane wrote:
> > 
> > 
> >>Anyone see a way out of this catch-22?  If not, which is the least
> >>bad alternative?
> > 
> > 
> > Ultimately, fix TRUNCATE to be transaction safe. This is non-trivial,
> > I know :-).
> > 
> > Regardless, the first option seems the less of the two evils.
> 
> Even though TRUNCATE was modeled after Oracle's TRUNCATE and 
> Oracle's TRUNCATE commits the running tx, truncates the 
> relation, and starts a new tx, regardless of whether or not 
> TRUNCATE is the first statement of the tx?

That seems just too harsh to me.  I think we should impose some
structure to it, though we will have compatibility issues.

--  Bruce Momjian                        |  http://candle.pha.pa.us pgman@candle.pha.pa.us               |  (610)
359-1001+  If your life is a hard drive,     |  13 Roberts Road +  Christ can be your backup.        |  Newtown Square,
Pennsylvania19073
 


pgsql-hackers by date:

Previous
From: Mike Mascari
Date:
Subject: Re: autocommit vs TRUNCATE et al
Next
From: Bruce Momjian
Date:
Subject: /contrib/retep to gborg