Re: PostgreSQL optimizer use seq scan instead of pkey index only scan (in queries with postgres_fdw)

From: Jeff Janes <jeff(dot)janes(at)gmail(dot)com>
To: Vitaly Baranovsky <barvetalforums(at)gmail(dot)com>
Cc: pgsql-performance(at)lists(dot)postgresql(dot)org
Subject: Re: PostgreSQL optimizer use seq scan instead of pkey index only scan (in queries with postgres_fdw)
Date: 2019-05-06 15:53:46
Message-ID: CAMkU=1z5ELvrLuMvh9VAKEyvnOaOqP92W2QbvzCbFqd2+_aWbw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

On Mon, May 6, 2019 at 11:38 AM Vitaly Baranovsky <barvetalforums(at)gmail(dot)com>
wrote:

> Thank you, Jeff!
>
> We'll be looking forward to the next version of Postgres in this case.
>
> As far as I understand, you've answered about sending filtering condition
> to a foreign server... Could you, please, clarify about another (the first)
> part of my question? Why the server choose seq scan instead of pk key index
> only scan for the local table?
>
> Thank you
>
>
Aren't those the same thing? The foreign server can't use the where
clause, if it doesn't get sent.

Cheers,

Jeff

In response to

Responses

Browse pgsql-performance by date

  From Date Subject
Next Message Vitaly Baranovsky 2019-05-06 16:36:56 Re: PostgreSQL optimizer use seq scan instead of pkey index only scan (in queries with postgres_fdw)
Previous Message Tom Lane 2019-05-06 15:53:19 Re: PostgreSQL optimizer use seq scan instead of pkey index only scan (in queries with postgres_fdw)