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 1kkaCV-0007Q4-LB for pgsql-general@arkaria.postgresql.org; Wed, 02 Dec 2020 22:02:15 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1kkaCU-0004RH-Hd for pgsql-general@arkaria.postgresql.org; Wed, 02 Dec 2020 22:02:14 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kkaCU-0004R9-8Q for pgsql-general@lists.postgresql.org; Wed, 02 Dec 2020 22:02:14 +0000 Received: from mout.gmx.net ([212.227.17.22]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kkaCR-0005w9-PW for pgsql-general@lists.postgresql.org; Wed, 02 Dec 2020 22:02:13 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1606946528; bh=ffDNBYL3MSxnrMCQbwRJwGv/6+wWGX4aepvhJal3+pI=; h=X-UI-Sender-Class:Subject:To:References:From:Date:In-Reply-To; b=Xt+unJGJ/Vsf93vR8aTClpY1eHcMa6gKmpJXTGyDmbVOsZtarbtvwVc13+NXmOpW/ lsEEpndpnPjT/UpGnEFaBae1rHKdq8UPOSGyiyFW+b1VOTu/bnjpg+OUVUUJFJOYhZ A0gOrKFXgLgstVtTLdFNDUDfmplUY7uY0qGAaidQ= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from [192.168.178.20] ([83.171.175.173]) by mail.gmx.com (mrgmx104 [212.227.17.168]) with ESMTPSA (Nemesis) id 1MzhnN-1jygVt1Od7-00vcrq for ; Wed, 02 Dec 2020 23:02:08 +0100 Subject: Re: Is the Halloween problem an issue in Postgres To: pgsql-general@lists.postgresql.org References: <756bd845-ebe1-4c45-88e8-0ab44bbc02b7@Spark> From: Thomas Kellerer Message-ID: <5f7e3d0e-52da-c5e4-72d6-edcff340d710@gmx.net> Date: Wed, 2 Dec 2020 23:02:07 +0100 User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; de; rv:1.8.1.21) Gecko/20090302 Thunderbird/2.0.0.21 Mnenhy/0.7.5.666 MIME-Version: 1.0 In-Reply-To: <756bd845-ebe1-4c45-88e8-0ab44bbc02b7@Spark> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: de-DE Content-Transfer-Encoding: quoted-printable X-Provags-ID: V03:K1:MO9x9HWjOskwnPdjD/xysAY6h0WnZ1rGPs0xV2aBnQ1PD0dsp1S g+rzlCBgga+P+M33cVRlPD8s7mx4+dXe0Uqu7x3dvI8Utm3MTE3j475yOePLm166WI7/mFB SZ6LVVhVntqbIu/G7EeYkm86U03zB2EB8rDygmQxI2ng2vZhLRXuzmZdSjy+CkdoPTM690x YqnAYqFCrBeoXuOSpz5pQ== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:fT5gu1WaVyw=:rV5jvMr+178KBCd7yO4JJE kZOj0mc4aVNcp8JC7p4KKO0mCbzDPpntFr48mbqnLJvYC8uPr25YYAc077TVwkCUkUMx2Ivhm uIcGRNA2tK9GKJqE6iIcA/xXlTKjUfmDMnV5RML3SeZkkpQ/Gq9vasL/2WKqqJuiuCB0uEp7N 6vbSoOPszY2sHPiFisJ7/PfyAoG5gQfnyILcttJ5ldGnu7u2sUCUmQW6VHjNqnQGFnkD7U7Sk CqHl3fWPz4PwdMPi9torN86lEORV0DKCBDiL+HArU3ubENN2cXnLe1dmUfASAKIqdy8Yk7NA0 +Pkk8Qx4h/bORAcu4hpT61a9xiFVDPs1dU/EGy70v0lK0Byq2LQGs+ADtaEYJ6hs8TQgTI4TW agzBgJ1LYtT+Kn3WyNo797zIx8zk1WbNzYm0VfBZnSb3DfOuNROJuHsqLHyqD4mlqF4jVAhe5 kzp8CQ2/hnVKzB4aOP480MpgzSW2dofIV9mzUB9caaN+imY1TTQ/d+a7JJ3fdlLAfi7XyD5Tb RUYQEGtFH7vn4aIHUh4QUN8ybavNMIAuiDngLbcbGs8GO3EUnbzFW3cBJ3+D+OsMZZBbJOP1P hi4SWqdOyk0rdyvk9/VF39S4er89zV0vBk7alOKwzDxqU2MFTIebBnheEKwE+iMTLNrNCa9Gg cU3/XXsJKfySxhpO8LINLf0OU9vDAAOJIy0vDai6zJ0x5IL8thh9j28n/dJJ2wxvQRmBML649 3m2Qsq7zi6ZiOyKeOX0HLt/hHUZhSlBqGsD5VEo1AUXlPLmOeB0AFyCQQ6MPmfmvhgrih/SIS Jz7+wFuEJJze04bNUv9UB72T63g/8AT/TZJr9VrCZozBQ58hTmsw2m0uUiu5wtdQHRSyacJPg GuHnbwgResV97fAxKGoQ== List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk guyren@icloud.com schrieb am 02.12.2020 um 21:27: > The Halloween problem is that it is a challenge for the database if > you=E2=80=99re updating a field that is also in the WHERE clause of the = same > query. > > I just saw a presentation from someone about how in SQL Server he > recommended writing changes to a temp table and then writing them to > the table as being much more efficient. It sounds strange to me, that this _is_ actually a problem. Why exactly is that a problem in SQL Server? And what are the consequences if you do it nevertheless.