tds_fdw icon indicating copy to clipboard operation
tds_fdw copied to clipboard

TDS_FDW - Question

Open oscarrfp opened this issue 8 years ago • 4 comments

I´m using TDW_FDW for postgresql

https://github.com/tds-fdw/tds_fdw

Is it possible to execute stored procedures from the link to sql server?

procedure that may or may not have variable input parameters

oscarrfp avatar Apr 02 '18 16:04 oscarrfp

Hi @oscarrfp,

No, I don't think you can call remote stored procedures with tds_fdw at the moment. You probably can't even set a stored procedure as a table's query parameter, since FreeTDS uses a separate API for querying SPs than the one used for querying tables.

GeoffMontee avatar Apr 02 '18 23:04 GeoffMontee

Hi @GeoffMontee

Maybe you know of some other option to handle stored procedures?

thankful in advance

regards

oscarrfp avatar Apr 03 '18 16:04 oscarrfp

DROP FOREIGN TABLE IF EXISTS fdw_server.xxx; CREATE FOREIGN TABLE fdw_server.xxx (SRV_NAME text) SERVER server OPTIONS (query ' exec sp_linkedservers '); select * from fdw_server.xxx;

this work for me

4321ip avatar Apr 05 '18 20:04 4321ip

@oscarrfp, did 4321ip's workaround help? If you aren't still having the issue please close this issue.

ghost avatar Nov 05 '18 20:11 ghost