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 1tHakq-008dls-7O for pgsql-general@arkaria.postgresql.org; Sun, 01 Dec 2024 03:36:16 +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 1tHakn-004FN6-6d for pgsql-general@arkaria.postgresql.org; Sun, 01 Dec 2024 03:36:14 +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 1tHakl-004FMt-S4 for pgsql-general@lists.postgresql.org; Sun, 01 Dec 2024 03:36:14 +0000 Received: from fhigh-a6-smtp.messagingengine.com ([103.168.172.157]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1tHakf-000Q5v-SA for pgsql-general@postgresql.org; Sun, 01 Dec 2024 03:36:11 +0000 Received: from phl-compute-08.internal (phl-compute-08.phl.internal [10.202.2.48]) by mailfhigh.phl.internal (Postfix) with ESMTP id AB2671140126; Sat, 30 Nov 2024 22:36:04 -0500 (EST) Received: from phl-mailfrontend-02 ([10.202.2.163]) by phl-compute-08.internal (MEProxy); Sat, 30 Nov 2024 22:36:04 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=aklaver.com; h= cc:cc:content-transfer-encoding:content-type:content-type:date :date:from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:subject:subject:to:to; s=fm3; t=1733024164; x=1733110564; bh=ziQ/atjvKkuWcCGFeqCYsPugIov1C9wG9reuhVwm3p4=; b= A83p79T3jU6h6CLMu7nKw01nU3X4oXxiQQGj2xbAywHfvR2WFozHSAvzh38M4dMd AgY5ovQ661fBsWc8pcaeOj5juxHjTmsF8AvdLD1+OAM7vPdsMSxghmxNU9oSuHwp qM3Ujsm2k1rKky11qPQUAq7obOXyYu35MrUkLbdBiKyrpZ+pEZuaUgJ6tGG4ruSG ghCbS97PxeTlgEhC8p8PMez0vR+PblNWgfGTaC+lckZN5PhPSW7y7wxTNynhb0id NB3f1xzqAdggdW6qa9NmHOF7TsVWeMPkfw/X/rrmtYxpCA9WN+ubWFZ+tBZxQLso uTTaT9FF6f/oImnbSc4qQw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:feedback-id:feedback-id :from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:subject:subject:to:to:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm1; t=1733024164; x= 1733110564; bh=ziQ/atjvKkuWcCGFeqCYsPugIov1C9wG9reuhVwm3p4=; b=N x8/hDBBNkuPLJpr00evek4tBhR1N1BjO4B/fvHdy/WOajW9RCVQxi6zFOPBnBZbt aeQ0szzJQmMzQGq5FkQj4gddd5Fb2i98d5wbllA1WomlKF2S7SXqx6USeoI6FGCL OZHUws9JtzYZc02hIod8CVd6fWSglAXmHGsaiCj8vRPvM0tUiirSVjBW10INSvfk E7lEstrIwWd6dHs6CvQ6y78Zg9A+MGNHpqiVL/C0+oIpyZq9qOmEbQwb31zPDWQo utqIp3xcJXMi8YTJhUAqRIy+Pe7qFuz6FKLS7Q9+eQUt4X9yoRL7kK99UOLQbxUj /qxWxtPovq0NqUqxKwVvQ== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeefuddrheeigdeitdcutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpggftfghnshhusghstghrihgsvgdpuffr tefokffrpgfnqfghnecuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnth hsucdlqddutddtmdenucfjughrpefkffggfgfuvfevfhfhjggtgfesthekredttddvjeen ucfhrhhomheptegurhhirghnucfmlhgrvhgvrhcuoegrughrihgrnhdrkhhlrghvvghrse grkhhlrghvvghrrdgtohhmqeenucggtffrrghtthgvrhhnpeefgeefieeutdfggfetgefg heekjeehteeileeigfetieekjedvieeviefgheevtdenucevlhhushhtvghrufhiiigvpe dtnecurfgrrhgrmhepmhgrihhlfhhrohhmpegrughrihgrnhdrkhhlrghvvghrsegrkhhl rghvvghrrdgtohhmpdhnsggprhgtphhtthhopeefpdhmohguvgepshhmthhpohhuthdprh gtphhtthhopehpohhpvghrihhgsgihsehmrghilhgsohigrdhorhhgpdhrtghpthhtohep uggrvhhiugdrghdrjhhohhhnshhtohhnsehgmhgrihhlrdgtohhmpdhrtghpthhtohepph hgshhqlhdqghgvnhgvrhgrlhesphhoshhtghhrvghsqhhlrdhorhhg X-ME-Proxy: Feedback-ID: i76984098:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Sat, 30 Nov 2024 22:36:03 -0500 (EST) Message-ID: Date: Sat, 30 Nov 2024 19:36:03 -0800 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: Errors when restoring backup created by pg_dumpall To: PopeRigby , "David G. Johnston" Cc: "pgsql-general@postgresql.org" References: <6a6439f1-8039-44e2-8fb9-59028f7f2014@mailbox.org> <9c5ba566-27b8-4e8c-bf7d-2dc561509991@mailbox.org> Content-Language: en-US From: Adrian Klaver In-Reply-To: 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 11/30/24 19:26, PopeRigby wrote: > On 11/30/24 18:41, David G. Johnston wrote: >> On Saturday, November 30, 2024, PopeRigby wrote: >> >> On 11/30/24 17:27, David G. Johnston wrote: >>> On Saturday, November 30, 2024, PopeRigby >>> wrote: >>> >>> On 11/29/24 17:47, Adrian Klaver wrote: >>> >>> On 11/29/24 17:34, PopeRigby wrote: >>> >>> psql:all.sql:4104: ERROR:  type "earth" does not exist >>> LINE 1: >>> ...ians($1))*sin(radians($2))),earth()*sin(radians($1)))::earth >>> >>> QUERY:  SELECT >>> cube(cube(cube(earth()*cos(radians($1))*cos(radians($2))),earth()*cos(radians($1))*sin(radians($2))),earth()*sin(radians($1)))::earth >>> CONTEXT:  SQL function "ll_to_earth" during inlining >>>  The earthdistance module is even getting added between >>> the table with the earth type is added, so shouldn't >>> there be no problem? >>> >>> >>> The fact that “earth” is not schema qualified leads me to suspect >>> you are getting bit by safe search_path environment rules. >>> >>> David J. >> >> Ah. How can I fix that? >> >> Since you are past the point of fixing the source to produce valid >> dumps…that leaves finding the places in the text the lack the schema >> qualification and manually adding them in. >> >> David J. >> > Oh boy. How can I prevent this from happening again? > In future schema qualify all references. For now in the dump file you could search for SELECT pg_catalog.set_config('search_path', '', false); and set to SELECT pg_catalog.set_config('search_path', 'public', false); -- Adrian Klaver adrian.klaver@aklaver.com