Etsuro Fujita fujita.ets...@lab.ntt.co.jp writes:
Maybe I'm missing something. But I don't think
postgresGetForeignPaths() marks the parameterized path with the correct
row estimate. Also, that function doesn't seem to estimate the cost of
the parameterized path correctly. Please find
(2014/02/18 12:37), Tom Lane wrote:
Etsuro Fujita fujita.ets...@lab.ntt.co.jp writes:
(2014/02/18 12:03), Tom Lane wrote:
The calling FDW is supposed to do that; note the header comment.
However, ISTM postgresGetForeignPaths() doesn't work like
that. It uses the same rowcount for all paths
Why does create_foreignscan_path() not set the rowcounts based on
ParamPathInfo when the path is a parameterized path? Please find
attached a patch.
Thanks,
Best regards,
Etsuro Fujita
*** a/src/backend/optimizer/util/pathnode.c
--- b/src/backend/optimizer/util/pathnode.c
***
***
Etsuro Fujita fujita.ets...@lab.ntt.co.jp writes:
Why does create_foreignscan_path() not set the rowcounts based on
ParamPathInfo when the path is a parameterized path?
The calling FDW is supposed to do that; note the header comment.
I'm not sure that it'd be an improvement to change the API
(2014/02/18 12:03), Tom Lane wrote:
Etsuro Fujita fujita.ets...@lab.ntt.co.jp writes:
Why does create_foreignscan_path() not set the rowcounts based on
ParamPathInfo when the path is a parameterized path?
The calling FDW is supposed to do that; note the header comment.
Understood. However,
Etsuro Fujita fujita.ets...@lab.ntt.co.jp writes:
(2014/02/18 12:03), Tom Lane wrote:
The calling FDW is supposed to do that; note the header comment.
Understood. However, ISTM postgresGetForeignPaths() doesn't work like
that. It uses the same rowcount for all paths of a same