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 1saQt0-008lUj-G7 for pgsql-hackers@arkaria.postgresql.org; Sun, 04 Aug 2024 02:22:18 +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 1saQsx-007lS0-SV for pgsql-hackers@arkaria.postgresql.org; Sun, 04 Aug 2024 02:22:15 +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 1saQsx-007lRs-Iz for pgsql-hackers@lists.postgresql.org; Sun, 04 Aug 2024 02:22:15 +0000 Received: from sss.pgh.pa.us ([68.162.161.243]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1saQsv-002xJO-2Z; Sun, 04 Aug 2024 02:22:14 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 4742MCnp292157; Sat, 3 Aug 2024 22:22:12 -0400 From: Tom Lane To: Tatsuo Ishii cc: pgsql-hackers@lists.postgresql.org Subject: Re: subquery and sub-SELECT In-reply-to: <20240804.104807.1230474056016095674.ishii@postgresql.org> References: <20240804.104807.1230474056016095674.ishii@postgresql.org> Comments: In-reply-to Tatsuo Ishii message dated "Sun, 04 Aug 2024 10:48:07 +0900" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <292154.1722738132.1@sss.pgh.pa.us> Date: Sat, 03 Aug 2024 22:22:12 -0400 Message-ID: <292155.1722738132@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Tatsuo Ishii writes: > In our documentations, "subquery", "sub-query", "sub-select" and > "sub-SELECT" are used. In English, are they interchangeable? Pretty nearly. I think "sub-query" can include DML such as INSERT RETURNING, whereas "sub-select" should only be a SELECT. (I'm not claiming that we've been perfectly accurate about that distinction.) The dashes definitely don't matter. regards, tom lane