Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [postgis-2.3]

Version 2.3 of PostGIS, a spatial database extender for PostgreSQL object-relational database, which is targeted for release in Sept 2016.

0
votes
0answers
26 views

How can I confirm the maximum size of a polygon for acurate use in a geometry column?

Suppose I have a table with a geometry column containing polygons created from points of lat and long values (SRID: 4326). Given an arbitrary lat and long location (again SRID: 4326) I want to query ...
1
vote
1answer
30 views

ST_ValueCount() returning multiple rows of same VALUE

I want to calculate the proportion of each pixel value in a raster after clipping a much larger raster to my area of interest. However, after clipping and saving the raster from PostgreSQL database/...
5
votes
0answers
62 views

Offline editing slides the attribute data over one column and ads an “fid” column

My QGIS 3.4 Madeira project is attached to a PostGIS database (Azure) and looks good. It contains two layers, one with points and one with polylines. Each item in the Pointz layer has about ten ...
2
votes
0answers
59 views

How to tune the performance of Nominatim Reverse Geocoding Application

Running the query directly to the PostgreSQL takes 3-8ms. The PostgreSQL can handle 500 concurrent connections. The Apache server is running on 8 core CPUs. Analyzing the Apache access logs: There are ...
1
vote
1answer
49 views

PosGIS KNN returns different results from QGIS hub spoke function

Following example here I have tried to get nearest neighbours where code is; CREATE TABLE model.hub_spoke_spokes3f AS SELECT hub.id AS hub_id, spoke.id, spoke.point_geom, ST_Distance(hub....
2
votes
2answers
150 views

Combining two spatial tables in PostGIS

I have two PostGIS tables with geometries. One with number attributes and one with letter attributes. Each table has two features (rows). I would like to apply a operation on both stables so that I ...
5
votes
1answer
64 views

Getting the distance traveled across road segments

so I have a query that takes an encoded polyline, segmentizes that polyline into smaller pieces, and matches each point on that segmentized line to a "road segment" from a separate table in my ...
3
votes
1answer
112 views

Get closest road-segment to segmentized LineString points

So I have a table that stores a bunch of traffic counts for various road segments across the country. I'm regularly getting real-time location data from vehicles that are moving around a given region ...
1
vote
0answers
143 views

ERROR: function st_straightskeleton(geometry) does not exist

I'm trying to calculate center line from polygon, so i'm trying to do with postgis function st_straightskeleton but it is rising the error of function not found. postgis version: POSTGIS="2.4.3 ...
0
votes
2answers
238 views

ST_Dump and “geometry dump” error

I am trying to dump a set of point/multipoint rows with this query: SELECT a.gid, a.nid, a.uid, a.cod_reg, postgis.st_dump(geom) FROM table a but I get this error ERROR: relation "...
0
votes
2answers
214 views

PostGIS & Python SQL Query formatting: Create Geometry only for entries that are not NULL

I think this is rather a formatting issue. I have a database with a geometry Column that sometimes contains points. Normally, it will be None/Null. When I format the SQL query in psychopg2 and python ...
2
votes
1answer
305 views

ST_MakeValid() leaving data unaltered?

I recently received a PostGIS instance and am trying to figure out how much of my current processing workflow (in proprietary tools) can be ported over to PostGIS. One of the most frequent tasks I ...
1
vote
0answers
248 views

Osmosis Extremely Slow After Postgres 9.6 Upgrade

I am seeing extremely slow processing times for syncing my local osm database with the master repo after a Postgres upgrade to 9.6 from 9.5 (Postgis 2.3 from 2.2). The syncing used to happen every day ...
1
vote
0answers
96 views

PostGIS: Query using spatial join using pgadmin3

I have created three tables ch01.restaurants (SRID 2163;columnsfranchise, geom), ch01.lu_franchises (lookup table, no geom field;columnsid, franchise), ch01.highways (SRID 2163;columnsgid, feature, ...
4
votes
1answer
4k views

Could not access file “$libdir/postgis-2.3” on Travis installation

I was searching for a long time to test on Travis my symfony application using postgis extension. I read the Travis documentation to enabled Postgis and my .travis.yml was this one: # Project ...
5
votes
1answer
148 views

Calculating area of intersecting polygons within severals overlapping buffers

I am working with.. an initial point layer (in blue) called : centroid_layer.shp an initial polygon layer (in green) of woods called : wood_zone.shp ..and I need to get the area of intersected ...
0
votes
1answer
169 views

PostgreSQL+PostGIS creating GeoJSON with ST_MakeLine

Trying to get a valid geojson response from my PostgreSQL(9.6.3) + PostGIS (2.3.2) to track routes. I have a table of GPS positions of the form: CREATE TABLE public.gps ( id integer NOT NULL ...
1
vote
0answers
111 views

Speeding up closest point query?

I'm using PostGIS/Tiger for a mapping solution. For a given longitude, latitude (derived when someone clicks on a point in my Google Map), I want to retrieve the closest point from my table. My table ...
3
votes
0answers
93 views

ERROR pj_get_spheroid_defn EXTENSION POSTGIS2_96 POSTGRES-9.6 [duplicate]

I recently had this error, and surely other people also are going to have when they update the POSTGIS and POSTGRESQL, so I want to share the solution. OS: CENTOS 6 (x86_64) Installed: postgresql-9....
1
vote
0answers
76 views

PostGIS populating existing table with imported shapefile

I have a PostGIS database with an empty table ch01.highways. With the following code, I want to populate the table: INSERT INTO ch01.highways (gid, feature, name, state, geom) SELECT gid, feature, ...
1
vote
0answers
90 views

Understanding the performance boost behind type casting in PostGIS

I am running a PostGIS server (version 2.3). I have a table with the following structure: - index: BIGINT - geometry: LINESTRING I was playing with some of my spatial queries (ST_Intersects in this ...
3
votes
0answers
33 views

osm2pgsql backwards compatability issue during my biannual elevation contours import process

Every two years when I upgrade to the latest debian stable I start from scratch with my elevation contours pgsql/postgis database. This year I spent an entire day trying to find some new combination ...
1
vote
0answers
171 views

Renderer error Could not create datasource for type 'postgis'

I am trying to setup osm on centos 7. I have been following this link http://qiita.com/nkmrtkhd/items/642ae1b8a996cc46d85c. Most of the steps work here but I needed to do some extra googling for ...
4
votes
1answer
2k views

How To Use ST_VoronoiPolygons() in PostGIS?

Sorry folks, I know it sounds like a lame question - and, yes I did read the manual... :-) I'm trying to make Voronoi diagrams around points I have in a PostgreSQL table. It should be rather easy - ...
1
vote
0answers
103 views

Make different buffer around buildings per region - ST_Buffer and ST_Intersection slow query

I am developing Python code to explore suitable sites for wind power development in some countries using spatial data and Postgresql/PostGIS. For that reason I have tried to process a buffer around ...
3
votes
1answer
379 views

QGIS Seem To Bypass PostgreSQL/PostGIS User Privileges/Permissions

I created a "Read-only" User in PostgreSQL via a Role with "SELECT" ONLY privilege on all tables in a schema as shown below: GRANT SELECT ON ALL TABLES IN SCHEMA [schema_name] TO [role_name] GRANT [...
0
votes
1answer
74 views

Error using Postgis 2.3.1

I installed PostgreSQL 9.6, PostGIS 2.3.1 and Pgadmin III on my computer, and I was reading the documentation, so I thought that would be a great idea see the function on practice and then modifie ...
1
vote
0answers
31 views

Bad PostGIS TIGER Geocoding Performance In Specific States But Not Others

Short version: What should I do when I get great geocoding performance for all but one installed state? Long version: I (not a DB expert) am running the PostGIS tiger geocoder on my machine, not a ...
1
vote
1answer
135 views

Strange result with ST_Distance, geography type and equator

I am getting strange results with distance queries in PostGIS using geography types and ST_Distance. According to the docs, ST_Distance should return the distance in metres between two geography ...
1
vote
1answer
51 views

Distance in polygon from points in postgis?

I've got two GeoJSON files. One is points (gas stations) and the other is the local administrative area. I'm wondering is it possible to calculate the farthest distance in that polygon from the point?
7
votes
4answers
528 views

Finding maximum distance point can be from polygon using PostGIS?

I have a hydrography dataset containing navigable waterways: ponds, lakes, rivers, and streams. I need to find the maximum distance ANY location within the state can be from a navigable waterway. I'm ...
3
votes
0answers
140 views

Vector layer parameter in QGIS script takes wrong layer

I have 6 postgis layers in my QGIS project and all of them have the same data source but different joined data. When accessing these layers from a python script with a vector layer parameter (like ...
2
votes
0answers
168 views

PostGIS topology: creation of topogeometry polygons for simplification

I am using PostGIS topology to manage a geologic mapping project. My basic topology is defined by linework. The interstital polygons are meaningful, but can be constructed simply from lines and ...
6
votes
1answer
126 views

Duplicate PostGIS view entries in QGIS

I've got a table called "MargamParkMap" - which is made up of polygons. One of the attributes in the table is "authors". I've created a view with the aim of merging the polygons by author. What I've ...
5
votes
1answer
614 views

Obtaining Each Unique Area of Overlapping Polygons in Postgres 9.6/Postgis 2.3

I have recently finished compiling Postgres 9.6/GDAL 2.2 and Postgis 2.3 and am looking to build a generic, efficient solution for obtaining each unique area of polygon overlap within a given dataset ...