Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1sGlHX-00Grep-V8 for pgsql-general@arkaria.postgresql.org; Mon, 10 Jun 2024 20:06:20 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1sGlHW-00Fj2H-Go for pgsql-general@arkaria.postgresql.org; Mon, 10 Jun 2024 20:06:19 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1sGlHW-00Fj29-6C for pgsql-general@lists.postgresql.org; Mon, 10 Jun 2024 20:06:19 +0000 Received: from mail.appl-ecosys.com ([50.126.108.78]) by magus.postgresql.org with esmtps (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1sGlHU-000zHK-3a for pgsql-general@lists.postgresql.org; Mon, 10 Jun 2024 20:06:18 +0000 Received: from salmo.appl-ecosys.com (salmo.appl-ecosys.com [192.168.55.1]) by mail.appl-ecosys.com (Postfix) with ESMTP id BB1892A2B7C for ; Mon, 10 Jun 2024 13:06:13 -0700 (PDT) Date: Mon, 10 Jun 2024 13:06:13 -0700 (PDT) From: Rich Shepard To: "pgsql-generallists.postgresql.org" Subject: Re: Multiple tables row insertions from single psql input file In-Reply-To: Message-ID: References: <7da8ec9-089-74ce-eb3-c88889b62c64@appl-ecosys.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Mon, 10 Jun 2024, Ron Johnson wrote: > With enough clever scripting you can create a .sql file that does almost > anything. Ron, My projects don't all use SQL so I'm far from a clever scripter. :-) > Most useful to you will be some number of "ALTER TABLE DISABLE > TRIGGER ALL;" statements near the beginning of the file, and their "ALTER > TABLE ... ENABLE TRIGGER ALL;" counterparts near the end of the file. Doesn't alter table primarily apply to existing row values for specific columns rather than inserting new rows and their column values? Thanks, Rich