PostgreSQL跨服务器查询? [英] PostgreSQL cross server query?

查看:266
本文介绍了PostgreSQL跨服务器查询?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否可以查询服务器2上的数据库并在服务器1中获取数据?那就是从远程服务器向我的本地服务器返回一组记录。

Is there a way that I might query a database located on "Server 2" and get my data in "Server 1" ? That is return a set of records from a remote server to my local one.

PS:不跨服务器查询数据库,因为我知道如何使用dblink来实现。

PS: Not cross database query on same server because I know how to do that with dblink.

更新:很好。

http://www.postgresonline.com/journal/index.php?/archives/44-Using-DbLink-to-access-other-PostgreSQL- Databases-and-Servers.html 的工作原理很吸引人。我的失败是在postgresql网站上的dblink文档中没有看到它。

http://www.postgresonline.com/journal/index.php?/archives/44-Using-DbLink-to-access-other-PostgreSQL-Databases-and-Servers.html works like a charm. My bust was that I didn't see it on the dblink documentation on postgresql website.

推荐答案

显然,dblink可用于查询其他服务器-使用DbLink访问其他PostreSQL数据库和服务器

Apparently dblink can be used to query other servers - Using DbLink to access other PostreSQL Databases and Servers

这篇关于PostgreSQL跨服务器查询?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆