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 1tFUxB-00DKsy-C8 for pgsql-general@arkaria.postgresql.org; Mon, 25 Nov 2024 09:00:21 +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 1tFUx9-00Dgz2-7f for pgsql-general@arkaria.postgresql.org; Mon, 25 Nov 2024 09:00:19 +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 1tFUvO-00Dcku-Ef for pgsql-general@lists.postgresql.org; Mon, 25 Nov 2024 08:58:30 +0000 Received: from mail-oo1-xc32.google.com ([2607:f8b0:4864:20::c32]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1tFUvN-003k5a-0P for pgsql-general@lists.postgresql.org; Mon, 25 Nov 2024 08:58:29 +0000 Received: by mail-oo1-xc32.google.com with SMTP id 006d021491bc7-5f1e573f365so224990eaf.1 for ; Mon, 25 Nov 2024 00:58:28 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1732525107; x=1733129907; darn=lists.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=GUg+Qe4mFTzwsb7ObGT59iuQ+9o4qfFV7NHdGQgXxnQ=; b=Z3oXqKdo+i6/7fCGffzZQWyf8TRjeizjhMd7OSiEDBH7lPhwGYs6ERy7Hv5+hNAQr+ QnpWYBnik3J+gPpD2tFgsXTB6KBJNYbgrPJlzVtIYkuM464IQBkOXiWnTsgri9AktZ5O 5BT/lSoOLDFa6yv3GlmYQvveqVkBZC8aEoCXVbbxhQfWZCD+Qw32hreYGJ9OdLVu5PyI gCYzHl1jutgkPDJqkk5RuOkedgTke7ok7hUp0JUjmWbEWszsSbjARjqcrWmfDuT6Gb8B qPvCWRTgl1bJqtj/T4royALYr9X/ZR1syQx3PBx+956FLyksPhcsSsDss5EpRmvynzfe krlQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1732525107; x=1733129907; 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=GUg+Qe4mFTzwsb7ObGT59iuQ+9o4qfFV7NHdGQgXxnQ=; b=Mi8RJznTAqHiSaQaC338UeK0jWZ5fJF8l38gkcc/7h/k7NA5a0mXL6ZsI0riVJVQ4K EbyOpBlc4gC69UcGc/e6DeGLUsqpaUyqDvgp+DCk/URYG1kuUvPDEs3u3eRnzK0rh4f0 fHBzU8Out97E/90XKTBF2wPuWkE9SJPf7TUxAiDS/fc3BvBMD7StFOyARV48VWKzdOWC pVHkVALYqK/UAuVO060JxB1C1Zh4MiB5a9dQ1nCQYuVs3hNzyo6IPaBv/zRnoRDEI4NV inbcCoO7L2cNn3pHOuQZ3YVpKpyOjC8maVLgjzcruopuxa9gsYNrFuVSD0x5U1iAWDOK ZHPw== X-Gm-Message-State: AOJu0YwhnDX0xOVnydGfWaXr9bx85r9x3WTpHFzMC4/FKrRMZjqLM0IM Hlmwq65M2n2lR1HEALk9kkE8pv4TdDE0uCB8VC4lko6f6QEjzucCN39tjJPFOT/YB/rkY2Z1XxM KuWZBYr6u05bIjGn4USI8mAAALaM= X-Gm-Gg: ASbGncuo4+cWLgTu/KatXAhERNWlteNMIH4d087GVvdsw5pz9Tx+PAGboofAnsVQJbZ vEnAce8GFez/11qDrAz4yaqj6BEzGxYQr X-Google-Smtp-Source: AGHT+IHnrs996DZuvBnkeD4E51rqF4vfGs2OOsVvC1zBg9Rm5SW5Q6e1S0Ac5aPloFKQYuUtmqKiifkTHzyrGNCZFGM= X-Received: by 2002:a05:6820:1ac9:b0:5ee:dc3f:4193 with SMTP id 006d021491bc7-5f06a926df2mr9722161eaf.2.1732525106947; Mon, 25 Nov 2024 00:58:26 -0800 (PST) MIME-Version: 1.0 References: In-Reply-To: From: David Mullineux Date: Mon, 25 Nov 2024 08:58:15 +0000 Message-ID: Subject: Re: Error creating materialized view To: Shaun Robinson Cc: pgsql-general Content-Type: multipart/alternative; boundary="000000000000906dc40627b8ef4f" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --000000000000906dc40627b8ef4f Content-Type: text/plain; charset="UTF-8" On Mon, 25 Nov 2024, 06:08 Shaun Robinson, wrote: > Hi, > > I'm currently testing an application with Postgres 17.2 and am getting an > error when creating a materialized view which works in version 16 and > below. The sql works fine running as a query, but adding the > create materialized view breaks it. > > The error comes when calling a custom function and the error is that a > relation doesn't exist (which it does as it works within the same query > when not creating a view). > > Is this a known issue in the version 17.2? > > Thanks > Shau > Can you please post the DDL statements so we can see? Thanks > can you > --000000000000906dc40627b8ef4f Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


On Mon, 25 Nov 2024, 06:08 Shaun Robinson, <srobinson@mdxperience.com> wro= te:
Hi,

I'm currently testing an application with Postgres 17.2 and am= getting an error when creating a=C2=A0materialized view which works in ver= sion 16 and below. The sql works fine running as a query, but adding the cr= eate=C2=A0materialized view breaks it.

The error c= omes when calling a custom function and the error is that a relation doesn&= #39;t exist (which it does as it works within the same query when not creat= ing a view).

Is this a known issue in the version = 17.2?

Thanks
Shau


Can you please post the DDL statements so we can see?
Thanks
can you
--000000000000906dc40627b8ef4f--