Skip to content
Snippets Groups Projects
Commit 52b63649 authored by Robert Haas's avatar Robert Haas
Browse files

Code review for commit dc203dc3.

Remove duplicate assignment.  This part by Ashutosh Bapat.

Remove now-obsolete comment.  This part by me, although the pending
join pushdown patch does something similar, and for the same reason:
there's no reason to keep two lists of the things in the fdw_private
structure that have to be kept in sync with each other.
parent f2305d40
No related branches found
No related tags found
No related merge requests found
...@@ -53,12 +53,6 @@ PG_MODULE_MAGIC; ...@@ -53,12 +53,6 @@ PG_MODULE_MAGIC;
/* /*
* Indexes of FDW-private information stored in fdw_private lists. * Indexes of FDW-private information stored in fdw_private lists.
* *
* We store various information in ForeignScan.fdw_private to pass it from
* planner to executor. Currently we store:
*
* 1) SELECT statement text to be sent to the remote server
* 2) Integer list of attribute numbers retrieved by the SELECT
*
* These items are indexed with the enum FdwScanPrivateIndex, so an item * These items are indexed with the enum FdwScanPrivateIndex, so an item
* can be fetched with list_nth(). For example, to get the SELECT statement: * can be fetched with list_nth(). For example, to get the SELECT statement:
* sql = strVal(list_nth(fdw_private, FdwScanPrivateSelectSql)); * sql = strVal(list_nth(fdw_private, FdwScanPrivateSelectSql));
...@@ -1016,8 +1010,6 @@ postgresGetForeignPlan(PlannerInfo *root, ...@@ -1016,8 +1010,6 @@ postgresGetForeignPlan(PlannerInfo *root,
* Build the fdw_private list that will be available to the executor. * Build the fdw_private list that will be available to the executor.
* Items in the list must match enum FdwScanPrivateIndex, above. * Items in the list must match enum FdwScanPrivateIndex, above.
*/ */
fdw_private = list_make2(makeString(sql.data),
retrieved_attrs);
fdw_private = list_make3(makeString(sql.data), fdw_private = list_make3(makeString(sql.data),
retrieved_attrs, retrieved_attrs,
makeInteger(fpinfo->fetch_size)); makeInteger(fpinfo->fetch_size));
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment