This is what we're using , don't forget to install db_link module
select * from dblink('host=1192.168.1.1 dbname=mydb port=5432 user=myuser password=my_password', 'select name from country') as t1 (proname name, prosrc text);
"Ferrell, Denise CTR NSWCDD, Z11" <denise.ferrell.ctr@navy.mil> writes: > I've looked thru the documentation and I can't find where PostgreSQL allows for database links (something similar to what's available in Oracle).
Closest thing we've got is foreign tables based on the postgres_fdw foreign data wrapper (or you could use a different wrapper if you want to link to a non-Postgres database).