官术网_书友最值得收藏!

Connecting to WFS service

This example is based on the ogr_fwd documentation, so it only shows the required stuff. A full example can be reviewed here:

https://github.com/robe2/pgsql-ogr-fdw

First let's create a foreign server:

CREATE SERVER fdw_wfs_test_opengeo 
FOREIGN DATA WRAPPER ogr_fdw
OPTIONS (
datasource 'WFS:http://demo.opengeo.org/geoserver/wfs',
format 'WFS');

Automagically bring in the schema:

IMPORT FOREIGN SCHEMA "topp:tasmania_cities" 
FROM SERVER fdw_wfs_test_opengeo INTO data_linked;

And issue a query against the foreign WFS table:

select city_name from data_linked.topp_tasmania_cities; 

Since this dataset contains only one record, our result should be Hobart.

主站蜘蛛池模板: 峨眉山市| 新巴尔虎左旗| 温泉县| 开阳县| 黔东| 苏尼特右旗| 都昌县| 朝阳市| 郸城县| 白玉县| 叙永县| 宝兴县| 开江县| 大冶市| 福建省| 漯河市| 饶河县| 德兴市| 安庆市| 库尔勒市| 精河县| 桑植县| 古丈县| 通化县| 西城区| 绵竹市| 三明市| 商洛市| 乡城县| 固安县| 剑阁县| 库尔勒市| 许昌县| 贡嘎县| 时尚| 固镇县| 鄢陵县| 新民市| 九龙坡区| 香河县| 邵武市|