Re: [HACKERS] CREATE TEMP TABLE .... ON COMMIT

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Gavin Sherry <swm(at)linuxworld(dot)com(dot)au>
Cc: pgsql-patches(at)postgresql(dot)org
Subject: Re: [HACKERS] CREATE TEMP TABLE .... ON COMMIT
Date: 2002-08-27 21:24:01
Message-ID: 200208272124.g7RLO1L20172@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-patches


Your patch has been added to the PostgreSQL unapplied patches list at:

http://candle.pha.pa.us/cgi-bin/pgpatches

I will try to apply it within the next 48 hours.

---------------------------------------------------------------------------

Gavin Sherry wrote:
> Revised patch is attached.
>
> Passes all regression tests relating to temp tables. (I am getting
> regression test issues with privileges.sql, rules.sql, conversion.sql).
>
> Gavin
>
> On Tue, 27 Aug 2002, Bruce Momjian wrote:
>
> >
> > Gavin, how are you doing with this. As I remember, the only remaining
> > issue was where to store the 'drop on commit' information in the
> > backend. If that is all there is, we can come up with a solution.
> >
> > ---------------------------------------------------------------------------
> >
> > Gavin Sherry wrote:
> > > On Fri, 9 Aug 2002, Tom Lane wrote:
> > >
> > > > Gavin Sherry <swm(at)linuxworld(dot)com(dot)au> writes:
> > > > > template1=# create temp table a (a int) on commit drop;
> > > > > ERROR: You must be inside a transaction to use ON COMMIT
> > > >
> > > > Surely that's only for ON COMMIT DROP, if you intend to offer the
> > > > others?
> > >
> > > I should have provided details of this in the email. SQL99 details the
> > > baviour as follows:
> > >
> > > If TEMPORARY is specified and ON COMMIT is omitted, then ON COMMIT
> > > DELETE ROWS is implicit
> > >
> > > This might give users a bit of a surprise so the effective behaviour is ON
> > > COMMIT PRESERVE ROWS.
> > >
> > > As for your question (and, perhaps, SQL99) I don't seen how it makes any
> > > sense to specify ON COMMIT outside of a transaction block.
> > >
> > > >
> > > > regards, tom lane
> > > >
> > >
> > > Gavin
> > >
> > >
> > > ---------------------------(end of broadcast)---------------------------
> > > TIP 5: Have you checked our extensive FAQ?
> > >
> > > http://www.postgresql.org/users-lounge/docs/faq.html
> > >
> >
> >

Content-Description:

[ Attachment, skipping... ]

Content-Description:

[ Attachment, skipping... ]

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

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Alvaro Herrera 2002-08-27 21:25:35 Re: [HACKERS] pg_attribute.attisinherited ?
Previous Message Bruce Momjian 2002-08-27 21:23:06 Re: [SQL] LIMIT 1 FOR UPDATE or FOR UPDATE LIMIT 1?

Browse pgsql-patches by date

  From Date Subject
Next Message Alvaro Herrera 2002-08-27 21:25:35 Re: [HACKERS] pg_attribute.attisinherited ?
Previous Message Bruce Momjian 2002-08-27 21:19:56 Re: CREATE INDEX error message