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 1tgOPx-00AHqI-PK for pgsql-general@arkaria.postgresql.org; Fri, 07 Feb 2025 13:29:14 +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 1tgOPw-001XRI-SY for pgsql-general@arkaria.postgresql.org; Fri, 07 Feb 2025 13:29:12 +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 1tgOPw-001XQq-Hx for pgsql-general@lists.postgresql.org; Fri, 07 Feb 2025 13:29:12 +0000 Received: from dverite2024.planet-service.net ([185.16.44.252] helo=mail.verite.pro) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1tgOPu-003m5W-0i for pgsql-general@lists.postgresql.org; Fri, 07 Feb 2025 13:29:11 +0000 Received: by mail.verite.pro (Postfix, from userid 1000) id EA8622C0CFC; Fri, 7 Feb 2025 14:29:07 +0100 (CET) Content-Type: text/plain; charset="iso-8859-15" Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 From: "Daniel Verite" Subject: Re: libc to libicu via pg_dump/pg_restore? To: "Paul Foerster" Cc: Adrian Klaver , Pgsql-General List In-Reply-To: Date: Fri, 07 Feb 2025 14:29:05 +0100 Message-Id: <669e44d4-01fd-4ae2-9918-4396a7f8f070@manitou-mail.org> X-Mailer: Manitou v1.7.3 List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Paul Foerster wrote: > >> pg_restore: error: could not execute query: ERROR: insert or update o= n table "table_1" violates foreign key constraint "..._fk" > >> DETAIL: Key (dokument_id)=3D(1000033680) is not present in table "...= ". > >=20 > > Is dokument_id an integer field? >=20 > Yes, it's a bigint. It's hard to imagine that the change of collation is related to the failure to create that constraint. When a value is present in the target table but the FK check does not find it, often the cause is index corruption. But if you've just imported that dump, the index on the target column should be brand new. Still, you may check it with pg_amcheck [1] or try rebuilding it just in case. [1] https://www.postgresql.org/docs/current/app-pgamcheck.html Best regards, --=20 Daniel V=E9rit=E9=20 https://postgresql.verite.pro/