PostGIS is an extension for the PostgreSQL object-relational database that adds support for geographic objects.

learn more… | top users | synonyms

1
vote
0answers
20 views

Which type in entities for PostGIS/Hibernate Spatial

I already manage to store, read and update PostGIS rows with Hibernate Spatial with a Point and a MLineString in a very simple case : a MLineString defining a road, display a point along this road ...
1
vote
0answers
12 views

How to process GeoJSON data and create hive table for spatial analysis

I am using the ESRI-GIS tool for hadoop for analyzing json data generated through ESRI products like ArcGIS. But I wanted to analyze spatial data from a PostGIS table for which I made geojson ...
1
vote
0answers
21 views

How can I associate a consistent polygon area with a set of attributes using a topology?

Consider the following topology. SELECT CreateTopology('topotestschema', 0, 0.01); CREATE TABLE topotest (id SERIAL PRIMARY KEY, data TEXT); SELECT AddTopoGeometryColumn('topotestschema', 'public', ...
1
vote
0answers
41 views

Join/append multiple, identical polygon layers into a single layer whilst retaining all attributes?

I have run some analysis (zonalstats) on different raster layers using the same analysis polygons. I want to concatenate all these different layers together, i.e. retain a single polygon and have a ...
1
vote
0answers
45 views

Postgis / QGIS Snap Point to Line

I'm trying to snap points to lines in postgis for use in QGIS, but cannot get it to work. I have one line in my line table (although it was created by merging multiple lines together) and about 600 ...
1
vote
0answers
48 views

PostGIS - Intersects feature to split into linestring

I would like to know if it's possible to intersect feature datasets (multipolygon, polygon, multilinestring and linestring) to get a result as a set of linestrings being split at each intersection ...
1
vote
0answers
31 views

Postgis Raster Unions Color Issues

Can someone explain to me what I am doing wrong here as I think I do not properly understand postgis raster bands. I have a set of geometries that I want to merge with a raster and created a raster ...
1
vote
0answers
26 views

How to dissolve inner polygons in a multipolygon

I'm trying to get the boundary of a collection of zip codes. Here is my current sql: SELECT ST_AsText(ST_SimplifyPreserveTopology((ST_Union(geom)), .003)) as poly FROM zcta5_data WHERE zcta5 IN ...
1
vote
0answers
38 views

How to calculate bus route transfer by using pgrouting?

Let say I have route 1 from A -> B -> C, route 2 from C -> B -> D, how can I write SQL for pgRouting which can let me have the result route 1 -> route 2 when I want to get the shortest path from A ...
1
vote
0answers
52 views

How to calculate the average distance among set of points as measure of closeness

I have three series (or tables) of points in PostGIS which I want to compare. I would like to know how "close" each series is when compared to the other two. In other words I would need some measure ...
1
vote
0answers
35 views

PostGIS Raster functions not working

Hopefully I have a simple question that I'm not phrasing correctly in google. I'm trying to learn about storing and producing rasters in PostGIS. There are tons of examples and documentation online ...
1
vote
0answers
76 views

Undefined symbol error when creating postgis extension

When trying to create postgis extension, I'm getting an error, no references in google on it. maptest=# CREATE EXTENSION postgis; ERROR: could not load library "/usr/pgsql-9.3/lib/rtpostgis-2.1.so": ...
1
vote
0answers
48 views

Merge overlapping GeoJSON GeometryCollections

I need to merge three overlapping GeoJSON GeometryCollections of Polygon. Ultimately, the end result needs to be a geom type for PostGIS (e.g. MULTIPOLYGON) so I can easily check if particular points ...
1
vote
0answers
42 views

Looking for free tools to automatically generate spatial data catalogue

I've recently inherited a whole bunch of spatial data (mostly shapefiles but some .gdbs) which relate to a bunch of different cities. I'm looking for a way to take an inventory of what data I've got ...
1
vote
0answers
46 views

Is there a Raster2pgsql GUI?

Has anyone ever attempted to create a raster2pgsql gui (like the shp2pgsql gui). As I am sometimes lazy to use command line, this could be a very nice to have.
1
vote
0answers
65 views

Collapse dual carriageway lines in PostGIS

I have OpenStreetMap data, which represents larger roads (e.g. dual carriageways, aka divided highways) as parallel lines. The question is answered for ArcGIS or Skeletron here, for example using ...
1
vote
0answers
57 views

Add polygons to PostGres to be queried by Nominatim

I'm trying to build out a geocoder that also returns the correct legislative district information from this data: http://www.census.gov/geo/maps-data/data/tiger.html I've got OSM data imported into a ...
1
vote
0answers
82 views

Open PostGIS layer with QGIS 2.2

I just upgraded QGIS from 1.8 to 2.2 and I am getting some troubles to open a PostGIS Layer. The connection with the server works fine, I can see all my tables, select the one I want to open and even ...
1
vote
0answers
50 views

PostGIS raster connection is not closed by MapServer

I'm using PostGIS raster in MapServer like this: TYPE RASTER DATA "PG:port=6432 dbname='mydb' user='postgres' password='1234' schema='public' table='truemarble' mode='2'" PROCESSING ...
1
vote
0answers
43 views

Implement a least cost path in a graph

I am trying to produce a routing functionality in a web-GIS that, given a start and an end point, will retrieve the least cost path taking into account points along edges representing major costs, ...
1
vote
0answers
31 views

Import raster to postgis and add a foreign key constraint

I use raster2pgsql to import raster files into a table with this command line: C:\Program Files\PostgreSQL\9.3\bin>raster2pgsql -s 4326 -M -F -a c:\temp\mun.tif public.basqui_raster | psql -U ...
1
vote
0answers
73 views

Gaussian plume model in PostGIS or geocouch

Does anyone know of existing code for dispersion modeling using Gaussian Plume or comparable model, that I could plug in / adapt to be used programmatically from PostGIS or alternatively via ...
1
vote
0answers
116 views

Why does QGIS crash when my PostGIS table has a primary key?

Configuration: PostGIS Library: 2.0.3 GEOS: 3.3.8-CAPI-1.7.8 Proj: Rel. 4.8.0, 6 March 2012 PostgreSQL 9.2.2, compiled by VC++ build 1600, 64 bit, running on Win2012 server 64 bit QGIS 2.2.0 - 32 ...
1
vote
0answers
49 views

Point in Polygon operation for 100G of data

I have lat/lon point locations for over a billion points, all based in the US. For each point I would like to generate a dataset that links them to their county and to their MSA according to US Census ...
1
vote
0answers
42 views

PostGIS automatically creating geometries after importing using QGIS DB Manager

I have a shapefile consisting of linestrings, in which some of the features have null geometry. Yet, after importing it to PostGIS, using QGIS' DB Manager, a geometry is created for those features ...
1
vote
0answers
26 views

Use pgRouting with a PaaS

Is it a way to use a postGIS/pgRouting enabled database with a PaaS like Windows Azure? If not, do you know alternatives?
1
vote
0answers
56 views

Focal Mean of neighbors using ST_DWithin on points in PostGIS

I'm trying to calculate focal means on a grid of points in PostGIS. I know that a raster calculation would be more efficient, but I only need to run the algorithm once to get the data, so I don't ...
1
vote
0answers
41 views

PostGIS 3D Extrude function

I selected buildings from OSM (which represents my city). I insterted a new column 'height' and I filled with a random number exactly number 2, so every building have 2metres altitude. Buildings are ...
1
vote
0answers
18 views

How to simplify a polygon down to X amount of points?

If I have a polygon that has 100000 points, how can I calculate what the tolerance should be to simplify it down to 1000 points using ST_SimplifyPreserveTopology?
1
vote
0answers
48 views

qGIS' Database Manager “Load as New Layer” Option Not Working

I'm trying to visualize some of my database queries on qGIS. I run a valid SQL query which returns a subset of my table that should be easily loaded as a layer. I then check "Load as new layer," ...
1
vote
0answers
34 views

Problem installing Aggregate Polygons Function in PostgreSQL 9.3

I'm new to PostgreSQL and I've been trying to run a sql function written by Dr. Horst Duester, found in http://www.kappasys.ch/cms/index.php?id=65&L=5, which is used to aggregate detached ...
1
vote
0answers
74 views

Geoserver WFS Fails to Load in OpenLayers

I'm working with Postgis->Geoserver->openlayers on localhost. I followed a Geoserver tutorial to import some nyc sample data into my postgres/postgis database and link it to Geoserver. The layer ...
1
vote
0answers
22 views

ST_SplitRight() in PostGIS?

I am looking to split a shapefile via a line. I am interested only in the feature that lies to the right of the line; exactly what ST_SplitRight does here. Do any of you know of a way to do this in ...
1
vote
0answers
58 views

Do ArcGIS clients that direct-connect to postgresql/postgis databases override configuration settings?

I went in to modify some settings on a Postgresql database via the PGAdmin config editor and some of the settings don't have their default values and they are higher because they've been overridden ...
1
vote
0answers
103 views

Broken PostGIS support GDAL

I'm having some problems with Postgres/PostGIS after rebuilding my GDAL library:( I wanted to add MrSID support in GDAL so rebuilt it with the MrSID SDK. Everything compiled ok and I am now able to ...
1
vote
0answers
47 views

How to define Z dimension on table with PostGIS for import in TileMill?

I'm trying to reproduce the idea behind this blogpost from Mapbox, but with other data, for example the ne_10m_populated_places_simple dataset from Natural Earth. By adding a z-dimension to the data ...
1
vote
0answers
32 views

How to SELECT one day's scene (Landsat 8 scenes)

I have a huge dataset of raster in PostGIS. Each scene is divided into tiles (tile-size 500x500). I was trying to SELECT rast FROM landsat8 WHERE ST_Intersects(rast, polygon). It runs very slow, ...
1
vote
0answers
255 views

QGIS loads PostGIS layers but DBManager can't connect

DB Manager can't connect to PostgreSQL, but "Add PostGIS Layer" can. My eventual goal is to save created layers to PostGIS. I assume I can do this using the DBManager Tool. I can alternatively use ...
1
vote
0answers
86 views

PyQGIS Dialog Plugin not resetting

I have written a PostGIS search plugin that works pretty well, except two things that I just cannot figure out a solution 1) When the dialog closes and then is reopened the previous query is still in ...
1
vote
0answers
142 views

How do I catch PostGIS/PostgreSQL RAISE messages in QGIS?

I have a trigger set up in PostGIS/PostgreSQL which will show a RAISE WARNING when an inserted or updated polygon is within a certain distance of some predefined planning constraints. I want this ...
1
vote
0answers
98 views

django---error in displaying data and displaying it on the map

. i am trying to display a feature queried from postgis. . i also designed a user input field to enter the id of the desired feature to be displayed. . i have already queried the attributes first ...
1
vote
0answers
25 views

Forcing Hash Join Query Plans using PostGIS

I'm currently testing PostGIS 2.0 in a Greenplum Appliance (Postgres 8.2 based) and have hit an incompatibility between PostGIS and the MPP Greenplum environment. The basic query below can't be ...
1
vote
0answers
68 views

How can I edit spatial data automatically on postgis and check for topology errors on said data whitout using shapefiles?

So, I have spatial data stored in postgis (points, lines and polygons) and would like to edit and update those in an Open Source software (quantum GIS, grass, etc.) to check for topologic errors, ...
1
vote
0answers
120 views

PostGIS: How to distinguish overlapping routes (i.e., LineStrings) based on their direction?

I have a set of routes which are represented by LineStrings in my PostGIS database. These routes represent journeys that people make. I want to come up with routes that (a) overlap, and (b) have the ...
1
vote
0answers
94 views

Fastest way to add shapely geometries to a PostGis database using geoalchemy2

I am looking for the absolute fastest approach to adding +10,000 shapely geometry objects to a PostGIS database using geoalchemy2. I'm having no speed issues when uploading to a localhost postgres ...
1
vote
0answers
54 views

PostGIS replace view crashes PostgreSQL server from ArcGIS script

I have the following script which when from ArcGIS (and a similar script from a QGIS plugin) will update a view. Every so often (around 1 in 5 times the script is run) it causes the PostgreSQL ...
1
vote
0answers
44 views

How can I obtain the unit of a projection SRID?

Given a projection SRID, is there a way I can obtain the coordinates unit string (meter, degree, ...) ? In PostGIS for example, it looks like it is present in the srtext column of spatial_ref_sys. ...
1
vote
0answers
168 views

How to create a regular polygon grid in Openlayers?

I am trying to create a grid in my map and do some calculations. I seen the following links:- Create regular polygon grid using postgis Create regular polygon grid inside a polygon using postgis ...
1
vote
0answers
99 views

Traversing all possible road routes

I have created a topology from OSM data and would like to simulate a car driving every possible route along the map. The purpose is to "survey" the osm data as if in a car. My ultimate objective is to ...
1
vote
0answers
56 views

How to get intersected points between polygon and line in desired order

I have polygon for example "POLYGON((5 1, 6 1, 6 5, 5 5, 5 1))" that I want to intersect with line "LINESTRING(0 2, 10 2, 10 3, 0 3, 0 4, 10 4)" and get intersection points in the order that they ...