Tagged Questions

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

learn more… | top users | synonyms

2
votes
2answers
62 views

Did I set up Tiger Geocoder incorrectly?

I set up Tiger Geocoder in PostGIS on my local box (PostGIS 2.1.3, PostgreSQL 9.3.5, Tiger 2013 data). The problem I'm running into is that on almost every street most of the points are clustered, ...
0
votes
0answers
45 views

R PostGIS convert SpatialPolygon to PostGIS table

I've been having some success in scraping some webdata and converting it from HTML to spatial data as originally asked here: Parse PHP/HTML to shapefile or similar I've been using R to both fetch the ...
3
votes
1answer
184 views

Extracting centerline of a Complex-Polygon in PostGIS/Python

Any idea how to extract the centerline of the following polygon (Fig1) using PostGIS functions or Python modules? I was trying Voronoi Function but thats not helpful for this kind of shape. I want ...
2
votes
0answers
87 views

N Nearest Neighbours efficiently PostGIS/Python

The data is worldwide about a million points, lat/lons, with an id and an importance value (0.0 to 1.0), and it's limited to being on land. Ideally I need to cluster all 1 million points into 100,000 ...
3
votes
1answer
65 views

PostGIS: Get closest point between geometry and Multipoint

I think my question is not that difficult for GIS professionals, but i didn't found an answer to my problem (even not in other questions). Problem: I have given two tables (table1,table2) with Points ...
2
votes
1answer
73 views

PostGIS - How do I create a line that directly connects two earth points without travelling over a geodesic?

In PostGIS 2.1.1, I've noticed that if I create two distant earth points with equal altitude and then create a line connecting them, as I gather interpolated Z coordinate data along the line my Z ...
1
vote
0answers
37 views

Convert multiline to polygon

perfect result Shapefiles How I can convert this closed line to polygon with PostGIS? I tried many functions like ST_Polygonize, ST_MakePolygon, ST_BuildArea. I got some results, but not a perfect ...
1
vote
0answers
47 views

Finding areas with high POINT density from PostGIS table using Python

I have a PostGIS table with thousands of POINT objects and I want to find areas that have a high density of points. I have the DBSCAN clustering algorithm implemented in Python which does exactly ...
1
vote
0answers
53 views

Why does the postGIS file lose geometry?

I am loading shapefile data from a GPS into PostGIS via Leica ZenoOffice. This apparently imports fine with it's geometry in the attribute table. However, when I add a postGIS layer in QGIS the file ...
0
votes
0answers
17 views

Dot density inside polygon (kml co-ordinates)

I have a kmz url(its not in local), which has so many polygons in it. Which contains co-ordinates something like: <LinearRing> <coordinates>138.878021,-34.971903,0.0 ...
0
votes
0answers
26 views

GDAL_Translate not compressing when NoData value is set

I am trying to compress a .TIF file using GDAL_Translate or GDAL_Warp. My Raster is 32mb to start with. When I use GDAL_Translate with the COMPRESS=PACKBITS option, it compresses to 1.9mb. However ...
4
votes
1answer
74 views

Should geometries be drawn using rhumb-line or great-circle paths?

I work with WGS-84 coordinates and, most of the time, my map display (luciadmap) is in Mercator projection. My client is surprised to see that, for a rectangular geometry: the line between the 2 ...
0
votes
0answers
17 views

openlayer wfs protocall reset on map zoom

By considering wfs-example example. I have added one layer on map with BBOX and savestrtegy and add controls(add,delete,modify and save). wfs = new OpenLayers.Layer.Vector("Editable Features", { ...
1
vote
0answers
26 views

Create “grid” of polygons with the same 3D area based on an underlying raster variable (e.g. DTM height)

This could apply to point or raster values but imagine a raster of a continuous variable such as height (DTM). Is there a way to create a complete coverage of polygons that will have an equal area, ...
2
votes
1answer
41 views

Error in installing PostGIS 1.5?

I am installing PostGIS 1.5. After giving the command ./configure, it is showing that: pQserverversion in -lpq not found. configure: error: could not find libpq. What does it mean? I am ...
1
vote
1answer
29 views

How to calculate the intersection between WFS layer and a PostGIS table

I need to calculate the intersections betweek a WFS layer and the geometries stored in PostGIS table. Then I should save the geometries of the intersections in a separate PostGIS table. Do you have ...
1
vote
0answers
49 views

Error when trying to visualize geography data with QGIS

I use PostGis, and want to use QGIS to visualize data. But I get error message when trying to show the points in the table. I create a table: CREATE TABLE poi ( id text NOT NULL, coord ...
1
vote
1answer
45 views

PostGIS - How to do ST_UNION on each feature of a geojson FeatureCollection

I have a simple geoJSON featureCollection composed of 2 features: featureCollection = {u'type': u'FeatureCollection', u'features': [{u'geometry': {u'type': `u'MultiPolygon', u'coordinates': ...
1
vote
2answers
143 views

Export polygon in geojson as multipolygon

Anyone knows if is there any way to export a polygon layer in geojson, as multipolygon? I have a multipolygon shapefile. But there are single and multi polygons. When I export it to geojson, I got ...
0
votes
0answers
28 views

uploading raster format tif to postgis through raster2pgsql

I have the same problem Uploading raster format(*.tif) to postgis through raster2pgsql How to you fix it, if it is a problem? Because my raster column is empty. Of if it's ok, what does it mean? ...
1
vote
1answer
37 views

Error while installing PostGIS 1.5

After giving the command ./configure, it is showing that: pQserverversion in -lpq not found. configure: error: could not find libpq. What does it mean? I am using Red hat Linux (32 bit) version ...
0
votes
1answer
32 views

WFS with authentication to PostGis (or to shape)

Is there a way to import data from a WFS layer to a Postgis table (or to a shape)? there are blogs explaining how to do it in 3 steps (http://anitagraser.com/2012/09/26/wfs-to-postgis-in-3-steps/) or ...
2
votes
2answers
134 views

PHP examples to replicate FeatureServer capabilities

I used FeatureServer before and I liked it. The only thing I didn't like, though, is that it needs some other dependencies to work. That's why I want to try PHP instead. I know that there are already ...
3
votes
2answers
63 views

How to get the regional maximum or minimum of raster data by using PostGIS?

If I have Mean sea surface pressure data in raster format, is it possible for PostGIS to look for regional maximum or minimum? So that I can locate the L or H as the chart shown below? (image source: ...
1
vote
0answers
37 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 ...
2
votes
3answers
74 views

Find point close to points from postgis table

I have a postgis point table with a large list of cities. I need to find duplicates in it, but only if they are 10km close each other, which means that is the same city. For example, I have 5 points ...
0
votes
0answers
21 views

Problem with Performance when accessing selected Features from PostGIS layers in QGIS using Python

I have 2 PostGIS layer in my QGIS project. They have about the same amount of data and a similar structure except that layerX has its PK on a single column and layerY has its PK on 4 columns. When I ...
1
vote
1answer
55 views

Geometry error in roadnetwork

I have a road network table. When I check st_isValid(the_geom)='f', I am getting an error: NOTICE: IllegalArgumentException: point array must contain 0 or >1 elements ERROR: Exception in ...
1
vote
0answers
30 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
1answer
65 views

Migrating data from Python to PostGIS

I have pandas DataFrame with these columns: point datetime value 1 Point(-24.6064453125 26.3683280945) 2014-09-11 19:00:00 24.885258 2 ...
1
vote
1answer
130 views

Get a single cluster from cloud of points with specified maximum diameter in postgis

I have on the order of 2M Geometry Collections with N (median: 2, stddev: 6.6, 75th: 6, 95th: 21) Point objects (repeated points allowed and important) in a PostGIS table. I want to identify clusters ...
0
votes
0answers
27 views

imposm2 to imposm3

I am using imposm2 to import osm data to postgresql database but recently moved to imposm3 which is still in development phase I want to know is there an easy way to convert imposm2 mapping file ...
2
votes
1answer
83 views

Export raster from QGIS 2.4 to PostGIS

How can I export a raster file out of QGIS (version 2.4) into a PostGIS database? I am looking for a module or python script.
1
vote
1answer
89 views

How to install postgis extension using an existent version on postgresql on OSX 10.9.4

I'm trying to install postgis using my existent version of postgresql. I tried doing: brew install postgis. But I'm getting the following error trying run create extension postgis; query ...
1
vote
1answer
46 views

What date was a table loaded into PostGIS

Is it possible to find out the date a table was loaded into a PostGIS schema using PgAdmin3? The tables are usually supplied from varying external sources.
2
votes
1answer
41 views

Is there a similar Esri “load data tool” on Postgres/PostGIS?

I have a remote PostGIS DB and tables with permissions and users, containing data that is being published on geoserver; and in the office locally, we have an ESRI corporative GDB that is being updated ...
1
vote
0answers
16 views

Map Rendering Issues [closed]

I have tried simplification of geometry using Postgis function (ST_Simplify) in a map, for map rendering issues. I am still not able to get a good result, are there any other steps to follow?
3
votes
0answers
62 views

Problem with performance when loading PostGIS layer using pyQGIS

I'm having a question on loading a PostGIS layer into the project from my QGIS plugin. The code is like this: uri1 = qgis.core.QgsDataSourceURI() uri1.setConnection(str(host), str(port), ...
2
votes
0answers
69 views

Is it possible to create an ellipse around a line in 3D space?

In Postgis 2.1.1, I have a line in 3 dimensional space connecting two antenna points on the earth's surface. Is it possible to create an ellipse around that line? I have a formula to compute the ...
1
vote
1answer
54 views

Copy tables from one server to another in PostgreSQL

I am trying to copy a number of tables from one server to another using PostgreSQL as part of reorganising our data structure. I am pretty new to PostgreSQL so haven't much experience with it. Is ...
2
votes
1answer
49 views

Polygon from line creation problem

I have a problem transforming a linestring into a polygon. The error is: ERROR: lwpoly_from_lwlines: shell must be closed So I checked but firstpoint and endpoint are the same. I tried to use ...
0
votes
2answers
254 views

How do I install PostgreSQL + PostGIS + MapServer + Python-MapScript on Ubuntu 12.04 LTS w/o compiling from source?

This question is similar to the one posted here... How to have PostGIS 2.1 and the Python osgeo library installed together without compiling from source? ...but since I'm new GIS Stack exchange, I ...
1
vote
1answer
44 views

PostGIS - ST_Difference query returns a dissolved result

I am using the ST_Difference to erase multipolygon feature by a mask. However, the query returns a dssolved multipolygon. The query is the following: '''SELECT ST_AsGeoJSON(ST_Collect(geom))::json ...
2
votes
0answers
235 views

How to correctly import GeoJSON in PostGIS? [closed]

I'm trying to migrate GeoJSON data to PostGIS database and I thought that ogr2ogr is the tool: ogr2ogr -f PostgreSQL PG:"host={} user={} port={} dbname={} password={}" test.geojson -nln ogr_test ...
2
votes
1answer
62 views

Problem when trying to style negative values in Geoserver via SLD

I have a PostGIS table that holds (numeric) values from -1 to +1. I would like to style these values in Geoserver so I created an SLD file in QGIS which looks like this: ---snip--- <?xml ...
1
vote
1answer
40 views

Different ST_AZIMUTH results for ST_PROJECT points along the same original bearing

I'm trying to develop some way of determining line of sight (LOS) between two geographical points about 1km apart or less using ST_3DINTERSECTS or something similar. BASIC PROBLEM: Along the way, ...
0
votes
0answers
26 views

Bulk insert geometry in PostGIS inserting geom from an already existing table in database

My goal is to bulk insert original data into a table I created within PostGIS. I want to insert geographical data into this same table as well; this geographical data already exists within my ...
2
votes
1answer
135 views

Installed PostGIS extension not listed for database

I have a PostgreSQL database with the PostGIS extension enabled. I know that this extension is enabled, since I am using PostGIS functions, and I can actually see the PostGIS functions. However, ...
2
votes
1answer
49 views

Find nearest distinct features to a point

I am trying to select a single distinct features closest to an XY point in PostGIS. So I can find a single record for each distinct code by using: Select Distinct ON (code) * FROM table; Which ...
2
votes
0answers
53 views

PostGIS “Overlay” Style Union, not “Dissolve” Style

I'm trying to use PostGIS to do a 'union' of polygons. When I Googled "PostGIS Union", I found the ST_Union function, which performs what I would call a 'dissolve,' not a Union. What I actually want ...