jdbc2_fdw
jdbc2_fdw copied to clipboard
PostgreSQL 10 support?
Hello! I have the following issue with PostgreSQL 9.6 and 10:
$ make USE_PGXS=1
jdbc2_fdw.c: In function ‘jdbcGetForeignRelSize’:
jdbc2_fdw.c:469:36: error: ‘RelOptInfo {aka struct RelOptInfo}’ has no member named ‘reltargetlist’
pull_varattnos((Node *) baserel->reltargetlist, baserel->relid,
^
jdbc2_fdw.c:512:16: error: ‘RelOptInfo {aka struct RelOptInfo}’ has no member named ‘width’
baserel->width = fpinfo->width;
^
jdbc2_fdw.c:529:41: error: ‘RelOptInfo {aka struct RelOptInfo}’ has no member named ‘width’
(10 * BLCKSZ) / (baserel->width + sizeof(HeapTupleHeaderData));
^
jdbc2_fdw.c: In function ‘jdbcGetForeignPaths’:
jdbc2_fdw.c:553:2: warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-after-statement]
PgFdwRelationInfo *fpinfo = (PgFdwRelationInfo *) baserel->fdw_private;
^
jdbc2_fdw.c:564:36: error: incompatible type for argument 3 of ‘create_foreignscan_path’
fpinfo->rows,
^
/usr/include/postgresql/9.6/server/nodes/pg_list.h:69:18: error: incompatible type for argument 6 of ‘create_foreignscan_path’
#define NIL ((List *) NULL)
^
jdbc2_fdw.c:567:36: note: in expansion of macro ‘NIL’
NIL, /* no pathkeys */
^
In file included from jdbc2_fdw.c:28:0:
/usr/include/postgresql/9.6/server/optimizer/pathnode.h:90:21: note: expected ‘Relids {aka struct Bitmapset *}’ but argument is of type ‘List * {aka struct List *}’
extern ForeignPath *create_foreignscan_path(PlannerInfo *root, RelOptInfo *rel,
^
jdbc2_fdw.c:563:12: error: too few arguments to function ‘create_foreignscan_path’
path = create_foreignscan_path(root, baserel,
^
In file included from jdbc2_fdw.c:28:0:
/usr/include/postgresql/9.6/server/optimizer/pathnode.h:90:21: note: declared here
extern ForeignPath *create_foreignscan_path(PlannerInfo *root, RelOptInfo *rel,
^
jdbc2_fdw.c: In function ‘jdbcGetForeignPlan’:
jdbc2_fdw.c:591:5: warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-after-statement]
PgFdwRelationInfo *fpinfo = (PgFdwRelationInfo *) baserel->fdw_private;
^
jdbc2_fdw.c:685:13: warning: enumeration value ‘LCS_NONE’ not handled in switch [-Wswitch]
switch (rc->strength)
^
jdbc2_fdw.c:715:12: error: too few arguments to function ‘make_foreignscan’
return make_foreignscan(tlist,
^
jdbc2_fdw.c: In function ‘postgresPlanForeignModify’:
jdbc2_fdw.c:1030:42: error: ‘RangeTblEntry {aka struct RangeTblEntry}’ has no member named ‘modifiedCols’
Bitmapset *tmpset = bms_copy(rte->modifiedCols);
^
jdbc2_fdw.c: In function ‘estimate_path_cost_size’:
jdbc2_fdw.c:1618:24: error: ‘RelOptInfo {aka struct RelOptInfo}’ has no member named ‘width’
width = baserel->width;
^
jdbc2_fdw.c: In function ‘set_transmission_modes’:
jdbc2_fdw.c:1939:16: error: too few arguments to function ‘set_config_option’
(void) set_config_option("datestyle", "ISO",
^
In file included from jdbc2_fdw.c:36:0:
/usr/include/postgresql/9.6/server/utils/guc.h:363:12: note: declared here
extern int set_config_option(const char *name, const char *value,
^
jdbc2_fdw.c:1943:16: error: too few arguments to function ‘set_config_option’
(void) set_config_option("intervalstyle", "postgres",
^
In file included from jdbc2_fdw.c:36:0:
/usr/include/postgresql/9.6/server/utils/guc.h:363:12: note: declared here
extern int set_config_option(const char *name, const char *value,
^
jdbc2_fdw.c:1947:16: error: too few arguments to function ‘set_config_option’
(void) set_config_option("extra_float_digits", "3",
^
<builtin>: recipe for target 'jdbc2_fdw.o' failed
make: *** [jdbc2_fdw.o] Error 1
See my pull request update/pg95 (no response from repo owner) which I believe will also allow compiling under 9.6 and 10.
I ended up using jdbc_fdw which does work with 9.5+ and the license was the same as postgresql. https://github.com/atris/JDBC_FDW