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

learn more… | top users | synonyms

1
vote
0answers
205 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
73 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
115 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
78 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
16 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
56 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
92 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
81 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
48 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
36 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
125 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
90 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
46 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
195 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
36 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
82 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
71 views

Interpretation of PostGIS geocode function ratings

Edit: I am using Postgres 9.2 and recently installed PostGIS along with the Tiger Geocoder from the extras folder and downloaded all the latest Tiger data. I have been testing the Tiger Geocoder ...
1
vote
0answers
36 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
96 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
59 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
307 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
80 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 ...
1
vote
0answers
97 views

Complexity of A-star algorithm using pgRouting in a graph

I'm using the A-star algorithm in pgRouting. It uses the Manhattan distance as a heuristics ((|dx|+|dy|)/2). What would be the time complexity in a standard route network? Based on Why is the ...
1
vote
0answers
137 views

Write Nominatim-like geocode query using only PostGIS functions?

I'm new to PostGIS and was anticipating being able to write geocode queries using only the functions provided by PostGIS. However, once I loaded my database using osm2pgsql and discovered tables like ...
1
vote
0answers
112 views

identify subgraphs within planet_osm_line table

I want to identify subgraphs within the planet_osm_line table of the osm2pgsql-schema. those subgraphs are classified by certain tags i want to check. My first attempt was to do this recursively with ...
1
vote
0answers
120 views

pgRouting results to LINESTRING geometry type

I am doing some routing queries, using pgRouting's second version of pgr_trsp function. What I can't do effectively yet is storing the results. That is, I want to able to store in a table: either ...
1
vote
0answers
94 views

Merging contour lines along tile boundaries

I am working with the CANVEC data set. The data in canvec is broken up in to mapsheets. eg. 116B04. I have data covering the entire province of the Yukon. I have merged all the data in to one ...
1
vote
0answers
82 views

Upgrading Postgres database to Postgis 2.1.1

I executed the postgres 9.1.6 with Postgis 1.5.8 dump from a remote server on Linux pg_dump -h localhost -p 5432 -U postgres -Fc -b -v -f "/somepath/tumidb9.1geom1.5.8.backup" tumidb9 So I have a ...
1
vote
0answers
54 views

Problems with versioning

I have 5 PostgreSQL_PostGIS database in my company and i conneting on them through ArcSDE. Four of database work correctly, only with one i have i realy big problem. When i make two versions of ...
1
vote
0answers
345 views

Failure to Access DBMS Server Error - ArcGIS/Postgres

If connected to an SDE enabled Postgres database via ArcGIS (10.1) for a long period of time, maybe an hour +, I will often receive an error from ArcGIS stating "Failure to access the DBMS Server[my ...
1
vote
0answers
60 views

How to get from GeoServer a KML of the external boundary of several areas

I have a GeoServer with PostGis database. PostGis database has a table with small geographic areas (English LSOAs and output areas, to be precise), with codes and shapes. I want to submit to ...
1
vote
0answers
43 views

Selecting a rectangle box from a raster tiled table in PostGis 2.1

I am new to PostGIS as well as SQL queries for rasters. I have imported a raster .tif file into PostGIS with tiles. I would need to select a bounded rectangle from within this raster using SQL ...
1
vote
0answers
98 views

SQL procedure(s) to convert GPS traces to an ordered set of junctions in a network

I have three datasets that I have loaded into a geodatabase (spatialite or PostGIS): A set of GPS points collected from individual trips through urban areas. Points have a unique point id, a group ...
1
vote
0answers
154 views

Smoothing Lines in PostGIS

I want to smooth Lines in postgis, to be more specific, I want to smooth road data from OpenStreetMap. Basicly I thought of something like this scenario. This would be a possible road segment. I ...
1
vote
0answers
43 views

Upgrade Postgres/Postgis

I have Postgres 8.4 and postgis 1.5.3 installed on centos6. Now I need to upgrade both to postgres 9.x and postgis 2.x. Is there somewhere a good tutorial how to upgrade without removing the old ...
1
vote
0answers
278 views

Using PostGIS with Postgres.app (9.3)

I'm trying to run CREATE EXTENSION postgis; on a fresh 9.3 Postgres.app install. I get this as a return: ERROR: cannot change return type of existing function HINT: Use DROP FUNCTION ...
1
vote
0answers
73 views

Use bbox in geoserver sql view

I'm doing this sql query using geoservers sql views: SELECT kmeans, count(*), ST_BUFFER(ST_CENTROID(ST_Collect(geom)), qrt(count(*))*1000 ) AS geom FROM ( SELECT ...
1
vote
0answers
23 views

Overview effect on postgis polygon table

Is There a Way, with postgis and qgis, to reproduce the overview effect of tiff Raster on a polygon table in order to increase speed? What if we could create simplified versions of this table,gathered ...
1
vote
0answers
174 views

GeoTools example for Shapefile export to already existing PostGIS table

I'm a newbie to GeoTool API, and I'm looking for a way to export the specific shapefile to the specific already existing PostGIS table with GeoTools (the underlying problem I face is that PostGIS ...
1
vote
0answers
27 views

PostGIS. Obtain the rotation between two equal Geometries

I've got two features with the same drawing (poliline) but one is rotated relative to the other. I would like no know in PostGIS the rotation between the two geometries to apply this rotation to a ...
1
vote
0answers
68 views

Is there tutorial available for PostGIS setup in ArcSDE 10.1 geodatabase on Linux?

Is there any tutorial for Set up PostGIS in an ArcSDE 10.1 geodatabase on Linux? There is one in tutorial arcgis 9 for ArcGIS version 9, but I couldn't find any for ArcGIS 10.1.
1
vote
0answers
73 views

PostGis search query on hstore tags

I am writing a search client, to query postgis db. The search query will be, SELECT tags->'name' AS name,ST_Transform(way,4326) AS pt_lonlattext FROM planet_osm_point WHERE lower(tags->'name') ...
1
vote
0answers
122 views

Problem import shapefile in PostGIS database

I am having a Polygon shape-file. When I try to import this shape-file in PostGIS some of the attributes in Geom Field is found empty. But in attribute table when I select that polygon It is visible ...
1
vote
0answers
265 views

Cannot add the PostGIS raster layer with QGIS

I've imported some raster data in PostGIS database with the following command: raster2pgsql -s 31468 -I -C -M -t 50x50 /home/stefan/Quantum\ GIS/Neumarkt/NM_NW.tif public.demelevation | psql -U ...
1
vote
0answers
52 views

How do I make vectorlayer with sql on PostGis via python code

I need to make a vectorLayer and fill with the SQL's results on PostGIS via python code. I'm working with python 2.7, QGIS 1.8 and PyQt 4.5 How do I it ? thanks
1
vote
0answers
225 views

Loop though records in PostGIS (using PL/PYTHON or PGSQL)

I've seen many example of loops, but I can't get that one to work. I work for a regional transit agency and each year, we conduct several surveys. I geocode everything to the house level for internal ...
1
vote
0answers
241 views

save features from openlayers to postgis via nodejs and websockets

I try to save features created on a vector layer (openlayers) to postgreSQL 9.1/postGIS 2.0 via websockets. As server I use nodejs 0.10.12 along with the pg module I cannot fix it. Its getting so ...
1
vote
0answers
170 views

MapServer Clustering GetFeatureInfo

I'm having a bit of a problem with clustering in map server the clustering itself works fine and the GetFeatureInfo works fine most of the time. However some times when I click on a cluster point it ...
1
vote
0answers
100 views

can Geocat Bridge enable me to connect to existing PostGIS database and make edits through ArcGIS?

We are planning to set up a Webgis to share our GIS data on the web. Currently, we are on a desktop GIS and using ESRI's File geodatabase format. We are considering ArcGIS Server or using Opengeo ...
1
vote
0answers
73 views

Can I speed up very long connection times to a PostGIS DB caused by complex views?

When connecting to a PostGIS database to add a postgis layer, all table and views are scanned by Qgis in order to define the geometry type (if I understand well the query performed). My problem is ...