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 1u6E4o-00CtLw-9E for pgsql-general@arkaria.postgresql.org; Sat, 19 Apr 2025 19:42:10 +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 1u6E4l-0012lg-3j for pgsql-general@arkaria.postgresql.org; Sat, 19 Apr 2025 19:42:07 +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 1u6E4k-0012lW-OZ for pgsql-general@lists.postgresql.org; Sat, 19 Apr 2025 19:42:07 +0000 Received: from mail.hjp.at ([212.17.106.138] helo=rorschach.hjp.at) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1u6E4i-000xCQ-0N for pgsql-general@lists.postgresql.org; Sat, 19 Apr 2025 19:42:07 +0000 Received: by rorschach.hjp.at (Postfix, from userid 1000) id B995A861F3; Sat, 19 Apr 2025 21:42:03 +0200 (CEST) Date: Sat, 19 Apr 2025 21:42:03 +0200 From: "Peter J. Holzer" To: pgsql-general@lists.postgresql.org Subject: Re: Error while updating a table Message-ID: <20250419194203.i6iksccdvqgck4cy@hjp.at> Mail-Followup-To: pgsql-general@lists.postgresql.org References: <1385521371.3160626.1744955370756.ref@mail.yahoo.com> <1385521371.3160626.1744955370756@mail.yahoo.com> <02e2740edf821e2ce84773c83065b45e9be890cc.camel@cybertec.at> <1852089030.3173833.1744961512201@mail.yahoo.com> <24bb716bbdb6dbb8ac02c501db26731a101d21d3.camel@cybertec.at> <1365122733.3205645.1744975213857@mail.yahoo.com> <45879321.3496225.1745066329503@mail.yahoo.com> <05820f63079333ff7e475e61b44c8378a03aa8e2.camel@cybertec.at> <1111108452.3502529.1745067987293@mail.yahoo.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="clsbootqcrrexjmo" Content-Disposition: inline In-Reply-To: <1111108452.3502529.1745067987293@mail.yahoo.com> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --clsbootqcrrexjmo Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 2025-04-19 13:06:27 +0000, sivapostgres@yahoo.com wrote: > Thanks Laurenz, > > it is 100% clear that an earlier statement in the same transaction must > > have got an error. Write your application so that it logs *every* error > > that comes from the database, then you are sure to catch that error. >=20 > There is an option to log every sql statement that's executed from the > application. Unfortunately, that option was not set at that time. You don't have to log every sql statement. Just the ones which cause errors. As Laurenz mentioned, that happens automatically with the default settings. > Even I enable it now, I can't figure out that error. =20 Just search the logs for the string "ERROR". > By any chance, if I get that statement, what should I do? 1) Read the error message. 2) Figure out what caused the error 3) Fix the problem hjp --=20 _ | Peter J. Holzer | Story must make more sense than reality. |_|_) | | | | | hjp@hjp.at | -- Charles Stross, "Creative writing __/ | http://www.hjp.at/ | challenge!" --clsbootqcrrexjmo Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEETtJbRjyPwVTYGJ5k8g5IURL+KF0FAmgD/IUACgkQ8g5IURL+ KF3dag//U9yKVgbTZEk73g9MkkZbG6jmz/rciWBMC5swqP9RDzB7wJC/p3uecgyZ rxTzA0OEQ8vlZPDv8BPyEObRE4oh//BNablT7LHWr8tyzrOxjjTGrjacBlH8mLih peiddGlgW3Lh++kc/fFptuYEeHYYt5jn3UgKzgxEhooQiKcY6hGg6ktchjNya5xX sOvBcWKHoDe6sCvXa1VckFIyYncO2QSsNR9lfcG2lmkXQrWYVHW4nSLs12HiPIMs Q4/JDJlACxK7N1uot6/uVJoEtaPT045cnZtDkDWJWXAJozjutoN6jGFqNQeOy+t1 CuNR0y/gQza6bRfPDwj6BRAzOcWAQVIVmusOcWD52D9aDx9NIvvAZuLXdH5L4N3T oQFqZ1FBmoZpKSKjkAIy5HpCeNasnOVB9R3eGul9OJSB8DsoWfgS78jQKA72Oyb1 1uxmOj+GSqQXGTAiHjB0uBIJvzWwnYiELNIB6WcblLU7AE6Iy/E9c5qzE34iGweY K1ykiIEQqqt8BlID1Lk5/ID2GpTLgpPNK5BwUeURtyQsHoN+I0/+K240p3FTVeEL 3VDBQj7ZKYl2hEcR9h4mj4PdPIcc8jvtEQzYN1O3NLbYoyuumuTc0jT6tLsOcdbP Bb8W7arsrMfHfOQM7aQWMvKVZzll89eGr8Uqc/mXyh+SAO36lq4= =q9qr -----END PGP SIGNATURE----- --clsbootqcrrexjmo--