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 1tFYcA-00Dqaz-K2 for pgsql-general@arkaria.postgresql.org; Mon, 25 Nov 2024 12:54:54 +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 1tFYc9-00F2n7-9e for pgsql-general@arkaria.postgresql.org; Mon, 25 Nov 2024 12:54:53 +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 1tFYc8-00F2mw-Tz for pgsql-general@lists.postgresql.org; Mon, 25 Nov 2024 12:54:52 +0000 Received: from mail-ed1-x534.google.com ([2a00:1450:4864:20::534]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1tFYc6-003h8k-8o for pgsql-general@lists.postgresql.org; Mon, 25 Nov 2024 12:54:51 +0000 Received: by mail-ed1-x534.google.com with SMTP id 4fb4d7f45d1cf-5ceca0ec4e7so5506033a12.0 for ; Mon, 25 Nov 2024 04:54:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cybertec.at; s=google; t=1732539288; x=1733144088; darn=lists.postgresql.org; h=mime-version:user-agent:content-transfer-encoding:references :in-reply-to:date:to:from:subject:message-id:from:to:cc:subject:date :message-id:reply-to; bh=QzUISgVcoiKr2YcYdV/DXPXMMX6Cm2xuBFvwwObLOOs=; b=RToqwUX2Tun/S10Jx96FzVRB48llD0oEYFyUkNBA5tQMWac2jD+sIf6zn6IvyviVu5 TYu8FVAJBopQfxgrJIMR9JyeNQcZ0m5Ha4WlE/48Q9q3FO9VmURRd7t8NEel6PKDtAvS JygHlXO6uFqZaaG3wbKUO9hypRFa1YDujJsD9qPuF2/aaHWhPlrxDkgxQsA9jgO/r8TB xjPIkBuDjMgIkSj6Pm3p7mkuK07lnclLN9AhnrXlbgcgN8O14yJKGz7Ew+Djm+UBVEEn sBks+TzL1QNrHITFb8bGSLIDcJNi0QxaC/WEfdxTQPUc7TxeTSDkEe7Ae8fcS/Zfa78B xkiQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1732539288; x=1733144088; h=mime-version:user-agent:content-transfer-encoding:references :in-reply-to:date:to:from:subject:message-id:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=QzUISgVcoiKr2YcYdV/DXPXMMX6Cm2xuBFvwwObLOOs=; b=s5kxdATw8kCqnyVlDB5rlw6j6AmcgoNfJWnrkOQkweGFV4E+u2G0sXbscSemCERwYr GuCzCAU8jqQy0cVDNKu7JoANyZYMVkRswYZ/EhpwK6vHFTXwT7/XH6GJKr1Pjq55ovUA ibs25vSJ/LMyE8kwa8uLh4ei1awYpsAAfsqhV7LGkt7exMqlT9C+VsQYWd3+9mzPweCE sdcruIliBX1Ls/HlHLyMPoKzI2ua+GTAXsGR5ia1xWD4RojkgYeoV9eDW3cJ70mTnSG7 K3AV/PzbUErO6xXUimr94+IN7G539oZ9vTkoAMsEuPmw0ea8VdnsD70o9hwUXpm+oHkE OFvA== X-Forwarded-Encrypted: i=1; AJvYcCXJUaKTGRIuMTUPACpuJ4wazD+vEGQpoRe8iQDtbrOCgV0fNqCHM5IujkynUGKQgYcMxh3vN1DkZAQorr31@lists.postgresql.org X-Gm-Message-State: AOJu0YyMFo79RJoNJJYTY+JbHNYkGtsFiibytn8qId2zPo93x4t2VFJl OPVuRks2BneAAcML0W1w0vRJkvj0Y4ZHLVp72hR7QLulV9EU48Gk8rSZP+9aJMOJXy0URRv1V7P w X-Gm-Gg: ASbGnct6p8fhmrziw29IFpAzlRBHn9lkhP+R/tGHWf68dR2wfwXq2EUHBNfwSlW6Wwg HcgWtzY1iGTk7bK7Ach2zJmG4GczkAVTFo69GHO5Zd1NWkryXoZyN2hQjZvYyhFppU/2TJio5sv rcmpKWMS9aeSkSbyHVf/khIEir7k5u3HdbeCUMrwUes/MqW70r76zw/Yu3qLOOsbMNLRHypXtNb 4y4oE/czv7KraYty/q6tU+jNkDgOx3CaRhwDliOxZe3FVq7oIFNUrjR8nXMMQWu8g== X-Google-Smtp-Source: AGHT+IEVUzGa9mDmUboC+vRYI+7fnZ6rgKRZoGFR1Or4+14J5nDnI5lkOVHJ2j+clAaxaDG5ErJpMw== X-Received: by 2002:a05:6402:1ed4:b0:5cf:bcc8:f490 with SMTP id 4fb4d7f45d1cf-5d0205f3f49mr11820739a12.11.1732539286671; Mon, 25 Nov 2024 04:54:46 -0800 (PST) Received: from localhost.localdomain ([2001:871:260:3360:8941:9d5e:c58:6]) by smtp.gmail.com with ESMTPSA id 4fb4d7f45d1cf-5d02a0fc5b5sm3527853a12.56.2024.11.25.04.54.46 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 25 Nov 2024 04:54:46 -0800 (PST) Message-ID: Subject: Re: Error creating materialized view From: Laurenz Albe To: Shaun Robinson , pgsql-general@lists.postgresql.org Date: Mon, 25 Nov 2024 13:54:45 +0100 In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable User-Agent: Evolution 3.52.4 (3.52.4-2.fc40) MIME-Version: 1.0 List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Mon, 2024-11-25 at 06:08 +0000, Shaun Robinson wrote: > I'm currently testing an application with Postgres 17.2 and am getting an= error > when creating a=C2=A0materialized view which works in version 16 and belo= w. The sql > works fine running as a query, but adding the create=C2=A0materialized vi= ew breaks it. >=20 > The error comes when calling a custom function and the error is that a re= lation > doesn't exist (which it does as it works within the same query when not c= reating > a view). >=20 > Is this a known issue in the version 17.2? That's a deliberate improvemen; see the first point in https://www.postgresql.org/docs/current/release-17.html#RELEASE-17-MIGRATIO= N you will have to schema-qualify all tables in the function or set the "search_path" on the function. Yours, Laurenz Albe