mirror of
https://git.postgresql.org/git/postgresql.git
synced 2025-01-30 19:00:29 +08:00
5b68d81697
We were emitting "(SELECT null::typename)", which is usually interpreted as a scalar subselect, but not so much in the context "x = ANY(...)". This led to remote-side parsing failures when remote_estimate is enabled. A quick and ugly fix is to stick in an extra cast step, "((SELECT null::typename)::typename)". The cast will be thrown away as redundant by parse analysis, but not before it's done its job of making sure the grammar sees the ANY argument as an a_expr rather than a select_with_parens. Per an example from Hannu Krosing. |
||
---|---|---|
.. | ||
expected | ||
sql | ||
.gitignore | ||
connection.c | ||
deparse.c | ||
Makefile | ||
option.c | ||
postgres_fdw--1.0.sql | ||
postgres_fdw.c | ||
postgres_fdw.control | ||
postgres_fdw.h |