dblink

dblink is a module that supports connections to other PostgreSQL™ databases from within a database session.

See also postgres_fdw, which provides roughly the same functionality using a more modern and standards-compliant infrastructure.