Closed ghost closed 4 years ago
What version of FreeTDS are you using?
1.0.8
does not work with PostgreSQL 11, and despite we didn't try with PostgreSQL 12, I suspect it's the same case because this error seems similar.
Try with v2.0.0-alpha.3. It should work fine, and it's covered by our CI.
Closing, I updated https://github.com/tds-fdw/tds_fdw/releases/tag/v1.0.8 to show that it's not compatible with PostgreSQL >= 11
I've a Centos 7, PostgreSQL 12 and tds_fdw 1.0.8. I got an error when I'm trying to: make USE_PGXS=1 PG_CONFIG=/usr/pgsql-12/bin/pg_config
src/tds_fdw.c: In function ‘tdsGetColumnMetadata’: src/tds_fdw.c:1250:70: error: invalid type argument of ‘->’ (have ‘FormData_pg_attribute’) char* local_name = festate->attinmeta->tupdesc->attrs[local_ncol]->attname.data; ^ src/tds_fdw.c:1255:71: error: invalid type argument of ‘->’ (have ‘FormData_pg_attribute’) column->attr_oid = festate->attinmeta->tupdesc->attrs[local_ncol]->atttypid; ^ In file included from /usr/pgsql-12/include/server/postgres.h:47:0, from src/tds_fdw.c:28: src/tds_fdw.c:1288:47: error: invalid type argument of ‘->’ (have ‘FormData_pg_attribute’) festate->attinmeta->tupdesc->attrs[ncol]->attname.data) ^ /usr/pgsql-12/include/server/utils/elog.h:125:14: note: in definition of macro ‘ereport_domain’ errfinish rest; \ ^ src/tds_fdw.c:1284:5: note: in expansion of macro ‘ereport’ ereport(WARNING, ^ src/tds_fdw.c: In function ‘tdsIterateForeignScan’: src/tds_fdw.c:1638:5: warning: implicit declaration of function ‘ExecStoreTuple’ [-Wimplicit-function-declaration] ExecStoreTuple(tuple, slot, InvalidBuffer, false); ^ make: *** [src/tds_fdw.o] Error 1