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 1swudP-006img-Us for pgsql-sql@arkaria.postgresql.org; Sat, 05 Oct 2024 02:35:08 +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 1swudO-00AHgW-Uv for pgsql-sql@arkaria.postgresql.org; Sat, 05 Oct 2024 02:35:06 +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 1swudO-00AHgN-IM for pgsql-sql@lists.postgresql.org; Sat, 05 Oct 2024 02:35:06 +0000 Received: from mail-oa1-x30.google.com ([2001:4860:4864:20::30]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1swudM-002XnV-1D for pgsql-sql@lists.postgresql.org; Sat, 05 Oct 2024 02:35:05 +0000 Received: by mail-oa1-x30.google.com with SMTP id 586e51a60fabf-2877d7ae3e5so1447822fac.3 for ; Fri, 04 Oct 2024 19:35:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1728095703; x=1728700503; darn=lists.postgresql.org; h=cc:to:subject:message-id:date:from:references:in-reply-to :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=x91uQUtvKVhr0PcQAfe/h31dg5qd/66bFKaRmkMjDfo=; b=QwHcDs2MXJ1QXJIEKxFTiBqrxQjy1NbueQ2fE80pH/yxoj93BwrwoDGYNzQwGw4aHC hZe0nKL1MO9c5DyyTfEEUKk5ddCUsE87eEj2KqqqMxATZKNN0DLOOcUOYaRwa8q59knb JWvGm4FHAKQ5lb6+fz6ZDl9PgNTRKPWwI8n6PF0m412B2ZgMIB38Pve3CzoAl/MzLd5Q Y0I30njneMKNxS4JyPIYbSlLkwf423ne6x9ANnT/7LsWDc/Y9hvYX+rVe8QRB2RnIU2u 6UMWcxRyWMqw5exAudh4KdN+a0HLTnxoUwMqniR0VLP3Wlzred6LuJCY3miY3y9rKMtb opkg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1728095703; x=1728700503; h=cc:to:subject:message-id:date:from:references:in-reply-to :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=x91uQUtvKVhr0PcQAfe/h31dg5qd/66bFKaRmkMjDfo=; b=gxgB/uW457x4eh5hxyokTCVJ4n+CyhhIvE27fDKKdMGHl5dd0eDjawW/ni78v9ytuv ddlDDG2WvUe1BKdTP9CD4Hr2PDHTd5KLKMdlI+o/eTDCPlOCa+wauP/3EKz3y+lXDqw0 xquTthoXc6nBmUoELTEQk4H24+7Fo0dRefxTLAgqSFsTBNPZCmoufmP6ARFrMrzRFkQ1 +Kz4AxPSpAxPz9gYu6NiqaJq1bA5gVdWwDp1iEyNMb1rK/xsTwsdQa5/aaM0W7klfFmZ QfY2AeH2xHgPDFwvTtqj7RCYwcQT+dEMy7m6jO1IjSUZT99GsF+enTeo/NNNPv7bcXtt IEIw== X-Forwarded-Encrypted: i=1; AJvYcCU8A+9k2T5NylsiMUIJXFGBH5m3pptfVTqhhqjAwj/UTt2hQxAynGBkJP9yOxNGszQvBO/CBU0znPI=@lists.postgresql.org X-Gm-Message-State: AOJu0YxFhyus7nRcGNIWtN2Q2zz7PKJPrGV/gN0kWRLhR5E8xAMlFbtZ gsXlsI6PN5zR+im1PW4XwfB7Cp5LfoFdzEQF9IdoEdMvGs9XwZlyF/JL51ilvjk1kiPf28JRX9O xfZCIsu5WwEekeBqZ94O9le6jrFk= X-Google-Smtp-Source: AGHT+IHUkxEIzyvshlau3C0A+K5dmznAOkPhUOfLbzWCQMHFMPX8yyFOCxm6w8Rwu47d7Rth16VR5KpcTsIDo+OH6xI= X-Received: by 2002:a05:6871:520b:b0:277:d7f1:db53 with SMTP id 586e51a60fabf-287c1da62f2mr3159541fac.17.1728095703318; Fri, 04 Oct 2024 19:35:03 -0700 (PDT) MIME-Version: 1.0 Received: by 2002:ac9:5992:0:b0:557:c384:fb61 with HTTP; Fri, 4 Oct 2024 19:35:02 -0700 (PDT) In-Reply-To: References: From: "David G. Johnston" Date: Fri, 4 Oct 2024 19:35:02 -0700 Message-ID: Subject: Re: invalid reference to FROM-clause entry for table To: Adw Spe Cc: Sam Stearns , "pgsql-sql@lists.postgresql.org" , Peter Garza , Henry Ashu Content-Type: multipart/alternative; boundary="00000000000088ca350623b1a217" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --00000000000088ca350623b1a217 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Friday, October 4, 2024, Adw Spe wrote: > Maybe I=E2=80=99m wrong, but I think every subquery must at least have a > SELECT-FROM pair. > You are indeed wrong - at least for PostgreSQL. No query requires a from clause in PostgreSQL. David J. --00000000000088ca350623b1a217 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Friday, October 4, 2024, Adw Spe <h.3stnc4kdbem6q_8p@outlook.com> wrote:

Maybe I=E2=80=99m wrong, but I think every subquery must at least have a SELECT-FROM pair.


You are indeed wrong - at least for Pos= tgreSQL.=C2=A0 No query requires a from clause in PostgreSQL.
David J.

--00000000000088ca350623b1a217--