Re: query plan worse after analyze - Mailing list pgsql-performance

From Tom Lane
Subject Re: query plan worse after analyze
Date
Msg-id 11261.1191649803@sss.pgh.pa.us
Whole thread Raw
In response to query plan worse after analyze  ("Jeff Frost" <jeff@frostconsultingllc.com>)
Responses Re: query plan worse after analyze
List pgsql-performance
"Jeff Frost" <jeff@frostconsultingllc.com> writes:
> Before analyze it seems to choose Bitmap Heap Scan on episodes
> current_episode, but after it chooses Index Scan Backward using
> index_episodes_on_publish_on on episodes current_episode.

Have you tried raising the stats target for "episodes"?  Seems like
the problem is a misestimate of the frequency of matches for
season_id = something.

            regards, tom lane

pgsql-performance by date:

Previous
From: Jeff Frost
Date:
Subject: Re: query plan worse after analyze
Next
From: Jeff Frost
Date:
Subject: Re: query plan worse after analyze