Re: Simple query with Planner underestimating rows.

2025-01-29 Thread Andrei Lepikhov
On 1/29/25 15:32, Felipe López Montes wrote: Hi, Thank you for your reply, I have already tried creating such statistics on t3.programme_identifier and t3.participant_identifier and the plan is the same, however I cannot create them for the right part of the join as they are from different t

Re: Simple query with Planner underestimating rows.

2025-01-28 Thread Andrei Lepikhov
On 1/29/25 02:29, Felipe López Montes wrote: Hi all, I am using PostgreSQL 17.2 on x86_64-pc-linux-gnu, compiled by gcc (GCC) 12.4.0, 64-bit. I have been facing this issue past weeks and I don't know what else to try, I have a very simple query where the planner is underestimating the numbe

Re: Simple query with Planner underestimating rows.

2025-01-28 Thread Greg Sabino Mullane
On Tue, Jan 28, 2025 at 5:30 PM Felipe López Montes wrote: > For the sake of clarity and simplicity, I have disabled the nestloop join > in the session because it involved a gather clause and parallel workers and > was still underestimating rows, so the same problem happens with nestloop > strate