From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com> |
Cc: | Gabriel Sánchez <gabrielesanchez(at)gmail(dot)com>, Postgres General <pgsql-general(at)postgresql(dot)org> |
Subject: | Re: Unused CTE affects result set |
Date: | 2023-11-17 18:48:54 |
Message-ID: | 674667.1700246934@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com> writes:
> On 11/17/23 10:30 AM, Gabriel Sánchez wrote:
>> I don't understand why the presence of a CTE that ends up not being
>> included in the final query affects the result set. Could this be a
>> bug, or is there something I don't understand?
> I would say it has to do with what '...' is doing?
We'd need to see a complete example to do more than speculate.
The planner definitely does skip unreferenced SELECT CTEs, though.
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Juan Rodrigo Alejandro Burgos Mella | 2023-11-17 19:32:31 | Re: Trigger to Count Number of Logical Replication Table Changes. |
Previous Message | Adrian Klaver | 2023-11-17 18:35:22 | Re: Unused CTE affects result set |