【Postgres】空间数据库创建

时间:2021-07-05 19:57:28

1、数据库创建问题-Navicat-ERROR: source database "template1" is being accessed by other users

【Postgres】空间数据库创建

【Postgres】空间数据库创建

2、解决方案

关闭Navicat

【Postgres】空间数据库创建

3、扩展PG的空间数据库功能

-- Enable PostGIS (includes raster)
CREATE EXTENSION postgis;
-- Enable Topology
CREATE EXTENSION postgis_topology;
-- Enable PostGIS Advanced 3D
-- and other geoprocessing algorithms
-- sfcgal not available with all distributions
CREATE EXTENSION postgis_sfcgal;
-- fuzzy matching needed for Tiger
CREATE EXTENSION fuzzystrmatch;
-- rule based standardizer
CREATE EXTENSION address_standardizer;
-- example rule data set
CREATE EXTENSION address_standardizer_data_us;
-- Enable US Tiger Geocoder
CREATE EXTENSION postgis_tiger_geocoder;

【Postgres】空间数据库创建