postgres_fdw: correct regression test for parameterized scan for foreign table

Started by Etsuro Fujitaabout 9 years ago1 messageshackers
Jump to latest
#1Etsuro Fujita
fujita.etsuro@lab.ntt.co.jp

Hi,

While working on adding support for parameterized foreign joins to
postgres_fdw, I noticed that commit
e4106b2528727c4b48639c0e12bf2f70a766b910 forgot to modify a test query
for execution of a parameterized foreign scan for a foreign table:

--- parameterized remote path
+-- parameterized remote path for foreign table
  EXPLAIN (VERBOSE, COSTS false)
-  SELECT * FROM ft2 a, ft2 b WHERE a.c1 = 47 AND b.c1 = a.c2;
+  SELECT * FROM "S 1"."T 1" a, ft2 b WHERE a."C 1" = 47 AND b.c1 = a.c2;
  SELECT * FROM ft2 a, ft2 b WHERE a.c1 = 47 AND b.c1 = a.c2;

The query in the last line as-is would test to see if the remote join
works correctly, which isn't the right thing to do here. Attached is a
small patch for addressing that.

Best regards,
Etsuro Fujita

Attachments:

postgresql-fdw-regress.patchbinary/octet-stream; name=postgresql-fdw-regress.patchDownload+10-10