pgsql: postgres_fdw: Fix tests with ANALYZE and remote sampling

From: Michael Paquier <michael(at)paquier(dot)xyz>
To: pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: pgsql: postgres_fdw: Fix tests with ANALYZE and remote sampling
Date: 2025-08-13 04:12:10
Message-ID: E1um2qQ-000ISD-28@gemulon.postgresql.org
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-committers

postgres_fdw: Fix tests with ANALYZE and remote sampling

The tests fixed in this commit were changing the sampling setting of a
foreign server, but then were analyzing a local table instead of a
foreign table, meaning that the test was not running for its original
purpose.

This commit changes the ANALYZE commands to analyze the foreign table,
and changes the foreign table definition to point to a valid remote
table. Attempting to analyze the foreign table "analyze_ftable" would
have failed before this commit, because "analyze_rtable1" is not defined
on the remote side.

Issue introduced by 8ad51b5f446b.

Author: Corey Huinker <corey(dot)huinker(at)gmail(dot)com>
Discussion: https://postgr.es/m/CADkLM=cpUiJ3QF7aUthTvaVMmgQcm7QqZBRMDLhBRTR+gJX-Og@mail.gmail.com
Backpatch-through: 16

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/783cbb6d5e8bdf87d321286f210983c177ead967

Modified Files
--------------
contrib/postgres_fdw/expected/postgres_fdw.out | 12 ++++++------
contrib/postgres_fdw/sql/postgres_fdw.sql | 12 ++++++------
2 files changed, 12 insertions(+), 12 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Peter Eisentraut 2025-08-13 13:10:11 pgsql: Clean up order in stylesheete-fo.xsl
Previous Message noreply 2025-08-12 22:06:28 pgsql: Tag refs/tags/REL_13_22 was created