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 1tH0Hf-002Rng-UQ for pgsql-admin@arkaria.postgresql.org; Fri, 29 Nov 2024 12:39:43 +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 1tH0Hd-007T2E-CU for pgsql-admin@arkaria.postgresql.org; Fri, 29 Nov 2024 12:39:42 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1tH0Hd-007T1x-0f for pgsql-admin@lists.postgresql.org; Fri, 29 Nov 2024 12:39:42 +0000 Received: from mail-yb1-xb35.google.com ([2607:f8b0:4864:20::b35]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1tH0Hb-000AHR-Px for pgsql-admin@postgresql.org; Fri, 29 Nov 2024 12:39:41 +0000 Received: by mail-yb1-xb35.google.com with SMTP id 3f1490d57ef6-e388503c0d7so1356858276.0 for ; Fri, 29 Nov 2024 04:39:39 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1732883978; x=1733488778; darn=postgresql.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=8puR19jzyR0jUinHP7PMZ/krj/UbsbmQ9He804bSeeE=; b=iFh///A3v4ZKujXLZXynsjJgUw/SKvcRKJl/u0ZxijIMuCgOPxWh3GNW9JBbsFvj+p IC7a06UWTWI5IJzPaIn3wwhHf8yuuCOL/rA9gbLT7+G+LjJAgkARWcCnZwIU6S0p192w dXqIyp15gOXhL0RtKNkCuw/tWlmqRIfVcoITniJVGekDEzr+13aeA2JX956IqHnHWvTZ BrfhbizBISnVk6fYu97PimePSQSLzrjHmPdH62DSsRYY4JRva3P1oBT2cSSp2UNKDQxP 7m8mZRa5zFconAqaZfGjQ+zO+W+rWGTkW2lWfVgthqCUih+pMvqbSnstiFdfabbbQCO3 AFvQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1732883978; x=1733488778; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=8puR19jzyR0jUinHP7PMZ/krj/UbsbmQ9He804bSeeE=; b=SMDBAMiiwR3MTYwnoSBlPx3xWLd0wAgn6O4try9KAVtz3H+Bv7en+dsCOr0Vyd3DB1 hb/Qa9iHsU12szSha37xCScVYthjgOTIS6j352yBVF3ClboDU9BRLb+cgfBaXYaFoX0E zlz3MBPb+j0HOeNTnmOMcKf+ZqgHKy5rRsy3ZRfjKE+VsmaZqOpXlDe4O6AxTkNtMUon bcZdJbYEYmJ6YJTO295O2Q45u9+c9te7elW8AAST8eU9Cvj68ysmsreKBcphw7xBEWp/ iICvidFcuXzFQKPjeQAuYjbyIfmdU4edCgSoju7zpaoSjczb594ZXsbOU8hpJ6Xxo5zl MICg== X-Forwarded-Encrypted: i=1; AJvYcCVdxa+e5ZoEeN3RinL1yCnBIWBrv1os3oByRcCrkn34cfkZB7WrW9HzWtFQE+s+wlIvRkbyU7U3btBgfg==@postgresql.org X-Gm-Message-State: AOJu0YxrmlC19geAAWrKfA6E0fqIUIQekhS27HKQihsaM7leCjgIcUgF WbGZa+lAb277XlWGiufy0dHTMy2RwVibEudBE8K0VnFobqTEA1AWYf+6Mcb8t+gqMiwBVDXzcvt T00wL/KlLcuuRQeF3fWcLthXM3sc= X-Gm-Gg: ASbGncsFCEIKZ0cEsA7bwYcIjdQZp8wn/HXxsx4UVoWqp2ux7W5qnOQZOi4DPv6Ovho 4FOB+xY2rdl9idjzsaXWrtW4rf6ZRPu0uvqX0hryg X-Google-Smtp-Source: AGHT+IGA7Z3gaNHW5zHFTRnx4a16ZeFvic/Yr5xZG7/1kB3R4AnCDaHrsro1EzfZeWuYPFz1zh4HQGfrUKjlVh0mZbw= X-Received: by 2002:a05:6902:2308:b0:e38:92b0:65dc with SMTP id 3f1490d57ef6-e395b8eacc3mr9407287276.26.1732883978474; Fri, 29 Nov 2024 04:39:38 -0800 (PST) MIME-Version: 1.0 References: In-Reply-To: From: Peter Gram Date: Fri, 29 Nov 2024 13:39:12 +0100 Message-ID: Subject: Re: Do postgres use implicit transaction in UPDATE ... RETURNING queries? To: Laurenz Albe Cc: Debraj Manna , pgsql-admin Content-Type: multipart/alternative; boundary="000000000000f95b3506280c7d57" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --000000000000f95b3506280c7d57 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hi Laurenz et al I would like to say in this way : Many clients like psql set autocommit on as default. It is up to the client to define the default and there are clients that default to autocommit off. Med venlig hilsen Peter Gram S=C3=A6byholmsvej 18 2500 Valby Mobile: (+45) 5374 7107 Email: peter.m.gram@gmail.com On Fri, 29 Nov 2024 at 11:10, Laurenz Albe wrote= : > On Fri, 2024-11-29 at 15:35 +0530, Debraj Manna wrote: > > Can someone let me know if Postgres 15 uses implicit transactions > for UPDATE...RETURNING queries? > > Yes, PostgreSQL always uses autocommit. > > Yours, > Laurenz Albe > > > --000000000000f95b3506280c7d57 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hi Laurenz et al

I would like to say in this way : = Many clients like psql set autocommit on as default.=C2=A0
It is up to the client to define the default and there are clients= that default to autocommit off.

=
Med venl= ig hilsen

Peter Gram
S=C3=A6byholmsvej 18=C2=A0
2500 Va= lby

Mobile: (+45= ) 5374 7107



On Fri, 29 Nov 2024 at 11:10, Laurenz Albe <laurenz.albe@cybertec.at> wrote= :
On Fri, 2024-1= 1-29 at 15:35 +0530, Debraj Manna wrote:
> Can someone let me know if Postgres 15 uses implicit transactions for= =C2=A0UPDATE...RETURNING=C2=A0queries?

Yes, PostgreSQL always uses autocommit.

Yours,
Laurenz Albe


--000000000000f95b3506280c7d57--