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

learn more… | top users | synonyms

1
vote
0answers
58 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
115 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
95 views

Editing PostGIS data in ArcGIS Desktop?

Quick question regarding editing PostGIS data in ArcMap 10.0. Far as I can tell, this can only be accomplished through third-party plugins like GISSquirrel or ST-Links. Does anyone know of an ...
1
vote
0answers
78 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
79 views

How do I automatically generate a spatial data catalogue from shape files and .gdbs?

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
44 views

PostGIS points to multipoint error

I have a table on PostgreSQL 9.2 ("POSTGIS="2.0.1 r9979" GEOS="3.3.3-CAPI-1.7.4" PROJ="Rel. 4.8.0, 6 March 2012" LIBXML="2.8.0""). This is it: CREATE TABLE nearest_point ( id_nearest_point serial ...
1
vote
0answers
71 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
125 views

Can't see Postgis layers added to QGIS

I'm trying to transition from an old Postgres/Postgis database to a new one. I'm working in a fresh install of Win 7 64 bit. I installed Postgresql 9.3 32 bit, then installed PostGIS 2.1.3. I created ...
1
vote
0answers
92 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
68 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
88 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
57 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
66 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
42 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
84 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
147 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
51 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
47 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
28 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
69 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
53 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
22 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
73 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
42 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
87 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
70 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
122 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
60 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
34 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
306 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
114 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
165 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
120 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
40 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
82 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
62 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
58 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
227 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
112 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
63 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 ...
1
vote
0answers
320 views

pgrouting php problem “pg_fetch_result(): Unable to jump to row 0 on PostgreSQL result index 3”

I'm trying to build a simple routing web-app using pgrouting, followed some tutorial and the latest workshop. Because I'm using PostgreSQL 9.3(x64), Postgis 2.1.1, and pgrouting 2.0 so I did some ...
1
vote
0answers
45 views

PostGIS layer attribute table empty in Quantum 2.0.1

I recently installed QGIS 2.0.1 (Dufour) on a Windows 7 PC (64-bit). Today I tried, for the first time since Dufour was installed, to load PostGIS layers into QGIS. I successfully set up a connection ...
1
vote
0answers
217 views

Finding the Closest Points using ST_ClosestPoint() for MULTIPOLYGON

I am working to match between the closest points of two tables. I have two tables: Building, SchoolBuilding. Building Table: Contains Polygones, SchoolBuilding Table: contains Points (From ...
1
vote
0answers
40 views

Create a single line from a resultset of line segments

How can I create a single line using the line segments geometry found in each row in resultset? I followed this tutorial: http://anitagraser.com/2013/07/06/pgrouting-2-0-for-windows-quick-guide/ I ...
1
vote
0answers
106 views

Find area with highest relative density of one type of object

I'm using PostgreSQL/PostGIS and I have an advanced type of query. My database contains two types of object - let's say pubs and churches :) Is there a way that I can find the area with the densest ...
1
vote
0answers
101 views

Need to enhance a function for creating quadrants within polygons

I wrote a function that creates arbitrary quadrants within a polygon SELECT (quadrant(20,0.0,90)).* The first parameter is the polygon ID, the second one is the start angle and with the third one ...
1
vote
0answers
82 views

Trajectory Indexing: How could I store and index the large trajectory dataset generated by cars' GPS?

I have a large trajectory dataset generated by cars' GPS. Since I will do some data mining work on them, I need an efficient way to store and index them. I read some papers about Trajectory Indexing ...
1
vote
0answers
486 views

Creating a spatial database using EXTENSIONS: error loading legacy.sql

I am using Postgres 9.3 and PostGIS 2.1, installed in a Docker container via RUN echo "deb http://apt.postgresql.org/pub/repos/apt/ precise-pgdg main" >> /etc/apt/sources.list RUN apt-get -y ...
1
vote
0answers
146 views

PostGIS Raster: raster2pgsql was not found in /usr/lib/postgresql/9.3/bin

I have installed sucessfully Postgresql-9.3-postgis on Ubuntu 12.04, following this instructions: http://trac.osgeo.org/postgis/wiki/UsersWikiPostGIS21UbuntuPGSQL93Apt Having done that, I have ...