From: Simon Riggs <simon@2ndQuadrant.com>
To: Robert Haas <robertmhaas@gmail.com>
Cc: pgsql-hackers@postgresql.org
Subject: Re: global temporary tables
Date: Sun, 25 Apr 2010 13:57:21 +0100
Message-ID: <1272200241.4161.1670.camel@ebony> (raw)
In-Reply-To: <i2z603c8f071004250350p35754194pd7821ce29c4461b3@mail.gmail.com>
References: <u2o603c8f071004231952i36642ae6u9d6a7eae6eb6ff32@mail.gmail.com>
<1272148142.4161.1598.camel@ebony>
<g2x603c8f071004241601qbca333edmd384f9a0df596417@mail.gmail.com>
<1272181795.4161.1604.camel@ebony>
<i2z603c8f071004250350p35754194pd7821ce29c4461b3@mail.gmail.com>
On Sun, 2010-04-25 at 06:50 -0400, Robert Haas wrote:
> On Sun, Apr 25, 2010 at 3:49 AM, Simon Riggs <simon@2ndquadrant.com> wrote:
> > On Sat, 2010-04-24 at 19:01 -0400, Robert Haas wrote:
> >
> >> There is one major problem, though: assigning a
> >> scratch relfilenode to the temporary table requires generating an OID,
> >> which we currently have no way to allow on the standby.
> >
> > Why not have an unlogged counter, which resets each system start, using
> > same datatype as an oid. There's no necessity for the relfilenode to be
> > an actual oid is there?
> >
> > That way we could use it on standbys also.
>
> I don't think that quite works, because the standby might assign a
> relfilenode number for a global temp table and then the master might
> subsequently assign the same relfilenode number to a regular table.
> We might be able to make that not matter, but it's far from obvious to
> me that there are no gotchas there...
That sounds fairly simple to solve.
All I am saying is please include "working on the standby" as part of
your requirement.
--
Simon Riggs www.2ndQuadrant.com
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-hackers@postgresql.org
Cc: simon@2ndQuadrant.com, robertmhaas@gmail.com
Subject: Re: global temporary tables
In-Reply-To: <1272200241.4161.1670.camel@ebony>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox