2 ms·
DuckDB is designed to be used as an embedded library, so it should be totally feasible to use it as part of a FDW. Alternatively, you can run DuckDB as part of
by mytherin 5y ago
DuckDB is designed to be used as an embedded library, so it should be totally feasible to use it as part of a FDW.
Alternatively, you can run DuckDB as part of a plpython function:
CREATE FUNCTION pyduckdb ()
RETURNS integer
AS $$
import duckdb
con = duckdb.connect()
return con.execute('select 42').fetchall()[0][0]
$$ LANGUAGE plpythonu;
SELECT pyduckdb();