简体   繁体   中英

How can i create foreign table with a condition

I have a table in other server for which I have to generate a foreign reference, but I don`t need all the data, I want to pull data based on a condition.

and also every time I query the foreign table it is going to actual table and fetching the data. how can I avoid that?

https://www.postgresql.org/docs/11/sql-createforeigntable.html

How to write the script

如果你不希望它每次都去获取数据,那么听起来你想要一个在外部表上定义的物化视图。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM