Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jiJJG-0005Q3-L4 for pgsql-general@arkaria.postgresql.org; Mon, 08 Jun 2020 15:03:34 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1jiJJF-00040k-JB for pgsql-general@arkaria.postgresql.org; Mon, 08 Jun 2020 15:03:33 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jiJFo-0002iZ-VA for pgsql-general@lists.postgresql.org; Mon, 08 Jun 2020 15:00:00 +0000 Received: from mail.am-soft.de ([83.218.36.120]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jiJFm-00082w-BG for pgsql-general@lists.postgresql.org; Mon, 08 Jun 2020 15:00:00 +0000 Received: from mail.am-soft.de (localhost [127.0.0.1]) by mail.am-soft.de (Postfix) with ESMTP id 5BBED29CDC7C for ; Mon, 8 Jun 2020 16:59:57 +0200 (CEST) Received: from tschoening-nb.fritz.box (unknown [77.78.178.44]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.am-soft.de (Postfix) with ESMTPSA id 3B56F29CDC7A for ; Mon, 8 Jun 2020 16:59:55 +0200 (CEST) Date: Mon, 8 Jun 2020 16:23:19 +0200 From: =?utf-8?Q?Thorsten_Sch=C3=B6ning?= Organization: AM-SoFT GmbH IT-Systeme Message-ID: <1451529478.20200608162319@am-soft.de> To: pgsql-general@lists.postgresql.org Subject: Re: Concurrenctly running CREATE TEMP TABLE IF NOT EXISTS [...] AS [...] In-Reply-To: <5fd32bf1-164c-742f-9e46-7c9cc547a0e1@gmail.com> References: <1102807465.20200608101409@am-soft.de> <5fd32bf1-164c-742f-9e46-7c9cc547a0e1@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-AV-Checked: ClamAV using ClamSMTP List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Guten Tag Ron, am Montag, 8. Juni 2020 um 15:35 schrieben Sie: > Would a set of GLOBAL temporary tables be a better fit for your problem > (eliminating the need to create temporary tables each time)? Do you mean plain tables simply created using CREATE TABLE or is there some additional concept of temporary tables I'm not aware of? Because I thought truly temporary tables are always session-specific:=20 > Temporary tables are automatically dropped at the end of a session, > or optionally at the end of the current transaction (see ON COMMIT > below). https://www.postgresql.org/docs/9.5/sql-createtable.html It totally depends on runtime and users if those tables are necessary at all in theory. So the benefit of using session-private once automatically maintained in my opinion is that I can introduce them easily as necessary without customizing my schema. My schema and all changes to it are versioned and I would like to avoid the maintenance overhead adding temp-tables which can easily change with the implementation using them. OTOH, if they are necessary at all at some point, the schema might be a good place to make aware of them, document their usage and stuff. i will think about that, so thanks for the hint! Mit freundlichen Gr=C3=BC=C3=9Fen, Thorsten Sch=C3=B6ning --=20 Thorsten Sch=C3=B6ning E-Mail: Thorsten.Schoening@AM-SoFT.de AM-SoFT IT-Systeme http://www.AM-SoFT.de/ Telefon...........05151- 9468- 55 Fax...............05151- 9468- 88 Mobil..............0178-8 9468- 04 AM-SoFT GmbH IT-Systeme, Brandenburger Str. 7c, 31789 Hameln AG Hannover HRB 207 694 - Gesch=C3=A4ftsf=C3=BChrer: Andreas Muchow