On 9/14/23 00:15, Ryo Yamaji (Fujitsu) wrote:
>
> Hi all
>
> I am planning to migrate from PostgreSQL9.2 to PostgreSQL14.7.
> Running the same SQL with the same statistics as previous versions resulted in different access plans.
> I have no knowledge of the PostgreSQL planner and would like to be informed. Please assist.
>
> Behavior:
> I am using an environment in which the statistics have been manually updated using pg_dbms_stats. (*)
Why not just run ANALYZE on the new 14.7 instance?
> In PostgreSQL9.2, the primary key was selected when a SELECT was executed with all columns of the primary key
specifiedas equals in the where clause.
--
Adrian Klaver
adrian.klaver@aklaver.com