有没有办法可以查询位于“服务器 2”上的数据库并获取“服务器 1”中的数据?那就是将一组记录从远程服务器返回到我的本地服务器。
PS:不在同一服务器上进行跨数据库查询,因为我知道如何使用 dblink 来做到这一点。
Update:太棒了。
http://www.postgresonline.com/journal/index.php?/archives/44-Using-DbLink-to-access-other-PostgreSQL-Databases-and-Servers.html http://www.postgresonline.com/journal/index.php?/archives/44-Using-DbLink-to-access-other-PostgreSQL-Databases-and-Servers.html奇迹般有效。我的失败是我没有在 postgresql 网站上的 dblink 文档中看到它。
这是旧的 - 如今人们会使用 postgres_fdw 模块来代替:https://www.postgresql.org/docs/9.3/static/postgres-fdw.html https://www.postgresql.org/docs/9.3/static/postgres-fdw.html
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)