atris / JDBC_FDW

FDW that wraps JDBC for PostgreSQL.It can be used to connect and fetch data from any data source that supports JDBC
Other
66 stars 38 forks source link

JDBC_FDW Build fails with Postgresql 10 #28

Closed learnerhub closed 6 years ago

learnerhub commented 6 years ago

@atris I am getting the following errors when building using command with Postgresql 10 => PATH=/usr/local/pgsql-10.0/bin/:$PATH USE_PGXS=1 make

jdbc_fdw.c: In function ‘jdbc_fdw_handler’: jdbc_fdw.c:372:29: warning: assignment from incompatible pointer type [enabled by default] fdwroutine->GetForeignPlan = jdbcGetForeignPlan; ^ jdbc_fdw.c: In function ‘jdbcGetForeignPaths’: jdbc_fdw.c:1060:2: error: incompatible type for argument 3 of ‘create_foreignscan_path’ add_path(baserel, (Path)create_foreignscan_path(root, baserel, baserel->rows, startup_cost, total_cost, NIL, NULL, NIL)); ^ In file included from jdbc_fdw.c:43:0: /usr/local/pgsql-10.0/include/server/optimizer/pathnode.h:107:21: note: expected ‘struct PathTarget ’ but argument is of type ‘double’ extern ForeignPath create_foreignscan_path(PlannerInfo root, RelOptInfo rel, ^ jdbc_fdw.c:1060:2: error: incompatible type for argument 6 of ‘create_foreignscan_path’ add_path(baserel, (Path)create_foreignscan_path(root, baserel, baserel->rows, startup_cost, total_cost, NIL, NULL, NIL)); ^ In file included from jdbc_fdw.c:43:0: /usr/local/pgsql-10.0/include/server/optimizer/pathnode.h:107:21: note: expected ‘Cost’ but argument is of type ‘struct List ’ extern ForeignPath create_foreignscan_path(PlannerInfo root, RelOptInfo rel, ^ jdbc_fdw.c:1060:2: warning: passing argument 8 of ‘create_foreignscan_path’ from incompatible pointer type [enabled by default] add_path(baserel, (Path)create_foreignscan_path(root, baserel, baserel->rows, startup_cost, total_cost, NIL, NULL, NIL)); ^ In file included from jdbc_fdw.c:43:0: /usr/local/pgsql-10.0/include/server/optimizer/pathnode.h:107:21: note: expected ‘Relids’ but argument is of type ‘struct List ’ extern ForeignPath create_foreignscan_path(PlannerInfo root, RelOptInfo rel, ^ jdbc_fdw.c:1060:2: error: too few arguments to function ‘create_foreignscan_path’ add_path(baserel, (Path)create_foreignscan_path(root, baserel, baserel->rows, startup_cost, total_cost, NIL, NULL, NIL)); ^ In file included from jdbc_fdw.c:43:0: /usr/local/pgsql-10.0/include/server/optimizer/pathnode.h:107:21: note: declared here extern ForeignPath create_foreignscan_path(PlannerInfo root, RelOptInfo rel, ^ jdbc_fdw.c: In function ‘jdbcGetForeignPlan’: jdbc_fdw.c:1079:2: error: too few arguments to function ‘make_foreignscan’ return (make_foreignscan(tlist, scan_clauses, scan_relid, NIL, NIL)); ^ In file included from jdbc_fdw.c:45:0: /usr/local/pgsql-10.0/include/server/optimizer/planmain.h:51:21: note: declared here extern ForeignScan make_foreignscan(List qptlist, List qpqual, ^ jdbc_fdw.c:1080:1: warning: control reaches end of non-void function [-Wreturn-type] } ^ make: *** [jdbc_fdw.o] Error 1

kostiantyn-nemchenko commented 6 years ago

Hi, @learnerhub jdbc_fdw is now compatible with PostgreSQL 9.6 and 10 since #29

learnerhub commented 6 years ago

Thank you. It works now. :)