Received: from maia.hub.org (unknown [200.46.204.183]) by mail.postgresql.org (Postfix) with ESMTP id 10D2B6331DC for ; Sat, 24 Apr 2010 23:57:14 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 49486-10 for ; Sun, 25 Apr 2010 02:57:03 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-iw0-f202.google.com (mail-iw0-f202.google.com [209.85.223.202]) by mail.postgresql.org (Postfix) with ESMTP id 7FEA6632D92 for ; Sat, 24 Apr 2010 23:57:03 -0300 (ADT) Received: by iwn40 with SMTP id 40so2206936iwn.1 for ; Sat, 24 Apr 2010 19:57:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:in-reply-to :references:date:message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=8JoK04iVr2J0ZJfUArpyuio7Z7KwtPsZMI3/TzwZsOs=; b=oCiGrVF9UrlXNy2iDwQZPlg/w8wJavE85OrvqFB4A/POd2tfk6U/KBH2ldoW+Dv89j 0l5gfouJhZUd+sD0ljh0+PNvtK8kDabQHFm6zDcoEce02gHC+vpXp15j/4YfHMvKjMHm V0/8FCyeBtA9BUBI3+aQq6lWKM86/BllIs76A= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; b=Ru5a2czRnI8JtVQrv5GabH/eN50tNeF2CyF9eFLlpsBA8ZVlsHzYboAn5ojZMXR30P x9M6HlFp91ZzrHw5ZZRYXbJ5+nVXuewPDV2SljCQKte4P3Ujcee19Vhezq763on6zX6s l9NX3jNYfwenbZ4V6GAk9DOK49IU4vmxEMHc4= MIME-Version: 1.0 Received: by 10.231.152.83 with SMTP id f19mr704008ibw.82.1272164222001; Sat, 24 Apr 2010 19:57:02 -0700 (PDT) Received: by 10.231.12.129 with HTTP; Sat, 24 Apr 2010 19:57:01 -0700 (PDT) In-Reply-To: <19198.1272162480@sss.pgh.pa.us> References: <7796.1272125493@sss.pgh.pa.us> <9319.1272130283@sss.pgh.pa.us> <18126.1272159451@sss.pgh.pa.us> <19198.1272162480@sss.pgh.pa.us> Date: Sat, 24 Apr 2010 22:57:01 -0400 Message-ID: Subject: Re: global temporary tables From: Robert Haas To: Tom Lane Cc: Jim Nasby , Greg Sabino Mullane , pgsql-hackers@postgresql.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.899 tagged_above=-10 required=5 tests=BAYES_00=-1.9, FREEMAIL_FROM=0.001 X-Spam-Level: X-Archive-Number: 201004/1147 X-Sequence-Number: 161259 On Sat, Apr 24, 2010 at 10:28 PM, Tom Lane wrote: > Robert Haas writes: >> Oh, maybe I do see. =A0If we pass it to smgropen() and stash it in the >> SMgrRelation, we don't have to keep supplying it later on, maybe? > > Right. =A0I'm unsure whether we should push it into the RelFileNode > struct itself, but even having it in SMgrRelation ought to cut out > a few places where it now has to be passed separately. Pushing it into the RelFileNode has some advantages in terms of being able to get at the information from everywhere, but one thing that makes me think that's probably not a good decision is that we somtimes WAL-log relfilenodes. And WAL-logging the value of the isTemp flag is a waste, because if we're WAL-logging, it's zero. ...Robert