Received: from localhost (maia-1.hub.org [200.46.204.191]) by postgresql.org (Postfix) with ESMTP id 525969FB9A6 for ; Mon, 2 Jul 2007 22:46:19 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.191]) (amavisd-maia, port 10024) with ESMTP id 98161-06-2 for ; Mon, 2 Jul 2007 22:46:10 -0300 (ADT) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.4 Received: from an-out-0708.google.com (an-out-0708.google.com [209.85.132.241]) by postgresql.org (Postfix) with ESMTP id 4E9239FBA4E for ; Mon, 2 Jul 2007 22:46:08 -0300 (ADT) Received: by an-out-0708.google.com with SMTP id c36so343204ana for ; Mon, 02 Jul 2007 18:46:06 -0700 (PDT) DKIM-Signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=auCmuDkb76wqb+CAAr9AyeBmgOe4RrupB453ms7N5f23M68+eOLi2e1gmXL0SVzo3bHL7xxR3T8f2U1Y3eoA5gCyCwQ6U0rUFq4YwYngsyeLU9us1aHDyM0ftblEyQaNLqaMNpFyx14XClkhJ7DTqgQzwClzr9iyWFLskeflfag= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=sYprMOO2zKTclRoFZ0YaDXY5nM3Cm+9z/nE8TN+wko6jo0dueh8mF6TCp6JhZbtmObksvBzOaSrVoljqkVHz8G9F88nDiXwNp4EKXtZvNmZcwi++Mm38Me1qE64dNEzZq7ReJESB7tWo98QgfKk8Lry9GnpbpXBxTvTCnlPhdbM= Received: by 10.100.47.9 with SMTP id u9mr1090006anu.1183427166815; Mon, 02 Jul 2007 18:46:06 -0700 (PDT) Received: by 10.100.45.15 with HTTP; Mon, 2 Jul 2007 18:46:06 -0700 (PDT) Message-ID: Date: Tue, 3 Jul 2007 01:46:06 +0000 From: "Jaime Casanova" To: "Alvaro Herrera" Subject: Re: what is difference between LOCAL and GLOBAL TEMP TABLES in PostgreSQL Cc: "Tom Lane" , "Jim Nasby" , "Pavel Stehule" , PostgreSQL-development In-Reply-To: <20070703004634.GB4757@alvh.no-ip.org> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: quoted-printable Content-Disposition: inline References: <162867790707011431u71e53543x19e64e5bb160b124@mail.gmail.com> <17505.1183326406@sss.pgh.pa.us> <19689F96-2FE1-4343-BE86-94317AEB0C57@decibel.org> <19728.1183394601@sss.pgh.pa.us> <20070703004634.GB4757@alvh.no-ip.org> X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200707/47 X-Sequence-Number: 104962 On 7/3/07, Alvaro Herrera wrote: > Tom Lane escribi=F3: > > Jim Nasby writes: > > > I've often thought that having global temp tables would be a really > > > good idea, since it would drastically reduce the need to vacuum > > > catalog tables, > > > > I rather doubt that. The most likely implementation would involve > > cloning a "template" entry into pg_class. > > How about a new relkind which causes the table to be located in > PGDATA/base//pg_temp_/ > > So each backend can have its own copy of the table with the same > relfilenode; there's no need for extra catalog entries. > we recently make the path for temp files to be just base/pgsql_tmp or pg_tblspc//pgsql_tmp. do we want to complicate things again? while not just a new rekind indicating this is a template and not and actual table. and using that template for creating the actual tables? --=20 regards, Jaime Casanova "Programming today is a race between software engineers striving to build bigger and better idiot-proof programs and the universe trying to produce bigger and better idiots. So far, the universe is winning." Richard Cook