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 1s92D2-00GuSQ-A8 for pgsql-general@arkaria.postgresql.org; Mon, 20 May 2024 12:33:45 +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 1s92D0-001WuL-MQ for pgsql-general@arkaria.postgresql.org; Mon, 20 May 2024 12:33:42 +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 1s92D0-001WuB-BX for pgsql-general@lists.postgresql.org; Mon, 20 May 2024 12:33:42 +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 1s92Cw-001BxQ-VN for pgsql-general@lists.postgresql.org; Mon, 20 May 2024 12:33:41 +0000 Received: from salmo.appl-ecosys.com (salmo.appl-ecosys.com [192.168.55.1]) by mail.appl-ecosys.com (Postfix) with ESMTP id 546182A43CF for ; Mon, 20 May 2024 05:33:37 -0700 (PDT) Date: Mon, 20 May 2024 05:33:37 -0700 (PDT) From: Rich Shepard To: pgsql-general Subject: Re: Updating 457 rows in a table In-Reply-To: <7F273F19-168F-4C66-85C5-B4BA8395E7A6@gmail.com> Message-ID: References: <164b3681-7a42-1e5-6a7b-80196ed33ded@appl-ecosys.com> <1E14886A-BBCB-40E4-8231-1159D12BD261@thebuild.com> <98639d1a-dddf-38e3-49b3-63632136a0f@appl-ecosys.com> <372F0968-BD78-45EB-AE70-015DBF923EBC@thebuild.com> <7e82178c-1249-b592-bfea-5152563ceb4c@appl-ecosys.com> <7F273F19-168F-4C66-85C5-B4BA8395E7A6@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8BIT List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Mon, 20 May 2024, Alban Hertroys wrote: > That aside, while you’re not absolutely 100% definitely sure that an > UPDATE or DELETE statement is going to do exactly what you intended, and > for good measure if you are, wrapping such statements in a transaction > allows you to ROLLBACK to get back to the state that you started from. Alban, That's excellent advice and I'll do so in all future data manipulation scripts. In the current situation psql did return that 457 rows had been updated. Much appreciated, Rich