From: | Andres Freund <andres(at)anarazel(dot)de> |
---|---|
To: | Simon Riggs <simon(at)2ndQuadrant(dot)com> |
Cc: | Jim Nasby <Jim(dot)Nasby(at)bluetreble(dot)com>, Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>, Zhaomo Yang <zhy001(at)cs(dot)ucsd(dot)edu>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>, Robert Haas <robertmhaas(at)gmail(dot)com> |
Subject: | Re: Implementation of global temporary tables? |
Date: | 2015-07-15 14:57:44 |
Message-ID: | 20150715145744.GJ5520@alap3.anarazel.de |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On 2015-07-15 16:52:49 +0200, Andres Freund wrote:
> Why do we need to create that copy? We can just use the relfilenode in
> all backends by having the backendid in the filename? Yes, there's a
> some amount of additional code needed, but it's not that much? I
> actually think it might end up being less additional code than having a
> copy, because with the copy you'll have two different oids for global
> entry and the local copy.
Hm, yes. Brainfart. Transaction table rewrites/truncations need to
change the relfilenode.
To fix We could add a backend local mapping table from global temp table
id to the backend local relfilenode. The code to lookup the relfilenode
is already mostly isolated.
From | Date | Subject | |
---|---|---|---|
Next Message | Robert Haas | 2015-07-15 15:01:48 | Re: First Aggregate Funtion? |
Previous Message | Andres Freund | 2015-07-15 14:52:49 | Re: Implementation of global temporary tables? |