Foreign data wrappers - PostgreSQL wiki
Want to edit, but don't see an edit button when logged in? Click here. Foreign data wrappers From PostgreSQL wiki Jump to navigation Jump to search Contents 1 Foreign Data Wrappers 1.1 Generic SQL Database Wrappers 1.2 Specific SQL Database Wrappers 1.3 NoSQL Database Wrappers 1.4 File Wrappers 1.5 Geo Wrappers 1.6 LDAP Wrappers 1.7 Generic Web Wrappers 1.8 Specific Web Wrappers 1.9 Big Data Wrappers 1.10 Column-Oriented Wrappers 1.11 Scientific Wrappers 1.12 Operating System Wrappers 1.13 Exotic Wrappers 1.14 Example Wrappers 2 Writing Foreign Database Wrappers Foreign Data Wrappers In 2003, a new specification called SQL/MED ("SQL Management of External Data") was added to the SQL standard.
It is a standardized way of handling access to remote objects from SQL databases. In 2011, PostgreSQL 9.1 was released with read-only support of this standard, and in 2013 write support was added with PostgreSQL 9.3. There are now a variety of Foreign Data Wrappers (FDW) available which enable PostgreSQL Server to different remote data stores, ranging from other SQL databases through to flat file. This page list some of the wrappers currently available.
Another fdw list can be found at the PGXN website . Please keep in mind that most of these wrappers are not officially supported by the PostgreSQL Global Development Group (PGDG) and that some of these projects are still in Beta version. Use carefully! Generic SQL Database Wrappers Data Source Type License Code Install Doc Notes ODBC Native github CartoDB took over active development of the ODBC FDW for PG 9.5+ JDBC Native github Not maintained?
JDBC2 Native github JDBC Native github README More recent than the above, advertises write support. SQL_Alchemy Multicorn PostgreSQL GitHub PGXN documentation Can be used to access data stored in any database supported by the sqlalchemy python toolkit. GDAL/OGR Native MIT GitHub yum.postgresql.org, apt.postgresql.org, and part of PostGIS windows bundle (application stackbuilder) Can access many kinds of data sources (Relational databases, spreadsheets, CSV files, web feature services, etc).
Uses the GDAL library which supports hundreds of formats to access the data. Exposes vector data as PostGIS geometry columns if you have PostGIS installed. Works great with both spatial and non-spatial data. VirtDB Native GPL GitHub A generic FDW to access VirtDB data sources (SAP ERP, Oracle RDBMS) APIs (via Steampipe plugins ) Native CLI and FDW extension: AGPL 3.0, Plugins: Apache 2.0 CLI on GitHub , FDW extension on GitHub Steampipe downloads Steampipe docs , Postgres FDW docs Steampipe bundles Postgres with an FDW extension that supports a growing ecosystem of plugins .
The plugins consume APIs, map them to tables, and enable queries within and across APIs. The plugins are also available as unbundled FDWs for use in any Postgres database. Specific SQL Database Wrappers Data Source Type License Code Install Doc Notes PostgreSQL Native PostgreSQL git.postgresql.org documentation Oracle Native PostgreSQL github PGXN website MySQL Native github PGXN example FDW for MySQL Informix Native PostgreSQL github DB2 Native github Firebird Native PostgreSQL github PGXN [1] version 1.4.2 released (2026-05-30) SQLite Native PostgreSQL github PGXN README An FDW for SQLite3 (write support and several pushdown optimization) Sybase / MS SQL Server Native github PGXN An FDW for Sybase and Microsoft SQL server MonetDB Native github NoSQL Database Wrappers Data Source Type License Code Install Doc Notes BigTable or HBase Native Rust Binding (RPGFFI) MIT Github Cassandra Multicorn MIT Github Rankactive Cassandra2 Native MIT Github Cassandra Multicorn PostgreSQL Github ClickHouse Multicorn BSD Github README ClickHouse Native Apache Github README ClickHouse Native Github README ClickHouse Native Apache GitHub PGXN documentation Interfaces to query ClickHouse databases from PostgreSQL ClickHouse Wrappers Apache GitHub documentation A foreign data wrapper for ClickHouse CouchDB Native PostgreSQL Github PGXN Original version CouchDB Native PostgreSQL Github golgauth version (9.1 - 9.2+ compatible) GridDB Native PostgreSQL Github README InfluxDB Native PostgreSQL Github README Kafka Native PostgreSQL GitHub README Kyoto Tycoon Native MIT Github MongoDB Native GPL3+ Github PGXN README EDB version MongoDB Multicorn MIT Github MongoDB Multicorn Github Yet Another Postgres FDW for MongoDB Neo4j Multicorn GPLv3 Github README FWD for Neo4j and also add a Cypher function to Pg Neo4j Native ?
Github Quasar Native Apache Github Redis Native PostgreSQL Github Redis Native BSD Github RethinkDB Multicorn MIT Github blog Riak Multicorn PostgreSQL Github RocksDB Native Apache Github README FDW for RocksDB SPARQL Multicorn2 PostgreSQL Codeberg WhiteDB Native MIT Github RDF Triplestores (SPARQL endpoints) Native MIT Github A Foreign Data Wrapper to easily access RDF Triplestores via SPARQL, including pushdown of several SQL query clauses.
File Wrappers Data Source Type License Code Install Doc Notes CSV Native PostgreSQL git.postgresql.org documentation Delivered as an official extension of PostgreSQL 9.1 / example / Another example CSV Multicorn PostgreSQL GitHub PGXN documentation Each column defined in the table will be mapped, in order, against columns in the CSV file. CSV / Text Array Native GitHub How to Another CSV wrapper CSV / Fixed-length Native GitHub CSV / gzipped Multicorn GitHub PostgreSQL Foreign Data Wrapper for gzipped cvs file Compressed File Native GitHub Document Collection Native PostgreSQL GitHub wiki JSON Native GPL3 GitHub Example Multi-File Multicorn PostgreSQL GitHub PGXN doc Access data stored in various files in a filesystem.
The files are looked up based on a pattern, and parts of the file's path are mapped to various columns, as well as the file's content itself. Multi CDR Native PostgreSQL GitHub PGXN Parquet Native PostgreSQL GitHub Foreign data wrapper for reading Parquet files using libarrow/libparquet Parquet Native PostgreSQL GitHub Foreign data wrapper for reading Parquet files using libarrow/libparquet. A fork of the Adjust FDW. pg_dump Native New BSD GitHub Allows querying of data directly against Postgres custom format files created by pg_dump TAR Files Native GitHub XLSX Native MIT GitHub README PG_Sheet allows reading XLSX Sheets via SheetReader , a fast Excel Sheet reader.
XML Multicorn PostgreSQL GitHub PGXN ZIP Files Native GitHub Geo Wrappers Data Source Type License Code Install Doc Notes GDAL/OGR Native MIT GitHub A wrapper for data sources with a GDAL/OGR driver, including databases like Oracle, Informix, SQLite, SQL Server, ODBC as well as file formats like Shape, FGDB, MapInfo, CSV, Excel, OpenOffice, OpenStreetMap PBF and XML, OGC WebServices, and more Spatial columns are linked in as PostGIS geometry if PostGIS is installed.
Geocode / GeoJSON Multicorn GPL GitHub a collection of PostGIS-related foreign data wrappers Open Street Map PBF Native PostgreSQL GitHub LDAP Wrappers Data Source Type License Code Install Doc Notes LDAP Native GitHub PGXN Allows to query an LDAP server and retrieve data from some pre-configured Organizational Unit LDAP Multicorn PostgreSQL GitHub PGXN documentation Generic Web Wrappers Data Source Type License Code Install Doc Notes Git Multicorn PostgreSQL GitHub PGXN Git Native MIT GitHub ICAL Multicorn PostgreSQL GitHub pdf IMAP Multicorn PostgreSQL GitHub PGXN documentation RSS Multicorn PostgreSQL GitHub PGXN documentation This fdw can be used to access items from an rss feed. www Native PostgreSQL GitHub PGXN wiki Allows to query different web services Specific Web Wrappers Data Source Type License Code Install Doc Notes OAI-PMH Native MIT GitHub README A PostgreSQL Foreign Data Wrapper to access OAI-PMH repositories (Open Archives Initiative Protocol for Metadata Harvesting).
This wrapper supports the OAI-PMH 2.0 Protocol. Cloudsmith.io Multicorn PostgreSQL GitHub Database.com Multicorn BSD GitHub Dun & Badstreet Multicorn PostgreSQL GitHub
The rest of this page is on the live site.