Version 2.0 of PostGIS brought a heavy set of new extensions for the PostgreSQL object-relational database, adding greater support for spatial objects.

learn more… | top users | synonyms

0
votes
1answer
29 views

ST_Dwithin Source Code

I am looking for the st_dwithin postgis source code. I want to learn the way postgis determines whether a given geometry is within a given radius to another geometry.
2
votes
1answer
69 views

Trouble using ST_Difference to remove overlapping features

I am trying to use ST_Difference to create a set of polygons (processing.trimmedparcelsnew) that do not contain any of the area covered by another set of polygons (test.single_geometry_1) using ...
0
votes
0answers
18 views

Problem importing sqlite into Postgres (with PostGis) using ogr2ogr

I am trying to import a very large sqlite file into Postgres SQL 9.3. The first tool I tried to use was OGR2GUI (http://www.ogr2gui.ca/). The 64 Bit version does nothing, whilst the 32 bit version ...
1
vote
1answer
675 views

Error saving polygon with hibernate spatial and postgis

I'm trying to persist a com.vividsolutions.jts.geom.Polygon in my PostgreSQL (with PostGIS enabled) database, using Hibernate and Hibernate-Spatial plugin. Caused by: ...
4
votes
1answer
148 views

Updating SRID (Update_GeometrySRID) does not alter polygons (when it should)

I am trying to change the SRID of polygons layer, but I'm having trouble visualizing the result. I the SRID is misreported the shapefile I used to import into PostGIS. The metadata says the ...
2
votes
1answer
327 views

PostGIS: ERROR: lwpoly_from_lwlines: shell must have at least 4 points

I have achieved to close lines in order to build a polygon with: st_addpoint( st_makeline(geom ORDER BY .cd_noseq), st_pointn( st_makeline(geom ORDER BY cd_noseq), 1) ) but ...
8
votes
1answer
101 views

Building a polygon over a reachable area

I am currently working in the field of isochrones and the underlying algorithms. What now causes problems is not the calculation if the isochrone itself, but the visualization of the results. The ...
0
votes
1answer
150 views

Delete all data from a PostGIS topology

I need to delete everything (faces, nodes, edges, anything I'm not thinking of) from a PostGIS topology, but I want to keep my database schema (schemas, tables, columns, sequences, etc.) intact. Is ...
4
votes
3answers
1k views

How to find lat/lon values for every pixel in a GeoTIFF file?

I want to a store GeoTIFF file pixel by pixel in the database. I need to store pixel values along with the lat/lon of that pixel on the GeoTIFF image. Is it possible to do that?
1
vote
0answers
31 views

What is the fastest way to select oldest, unique geometry from a table containing duplicates in PostGIS?

I have an output from an ArcPy arcpy.Union_analysis operation and for the overlap polygons that were created I need to select out the oldest feature (along with the attributes). The result is 75740 ...
1
vote
0answers
28 views

PyQgis - Adding attributes to a POSTGIS layer

After reading @underdark's answer to this question on creating a new vector layer and @Matthias Kuhn's to this one on field calculation, I wrote a script that allows me to calcultate the mean ...
2
votes
2answers
51 views

Is it possible to georeference raster stored in Postgis?

I'm looking to store a huge raster aerial image (400 Gb) into Postgis, but before storing it i like to know how i could georeference or rectify raster stored in postgis ? is there any Qgis plugins ...
4
votes
1answer
466 views

How can I make a Postgres/PostGIS ST_Distance_sphere query more efficient?

Within Postgres/PostGIS I have written an SQL query to get the closest distance for each element within a point coordinate table from a polyline table. The query comes back and works correctly, but ...
1
vote
1answer
190 views

PG::UndefinedFunction: ERROR: operator does not exist: point = unknown

Recently, I developed a feature to save and fetch points(lat and lon) from DB. It is working fine on my local, but on production database it is giving error: PG::UndefinedFunction: ERROR: operator ...
0
votes
1answer
21 views

PGR_Djikstra function error

I'm trying to find a shortest path between 2 nodes using djikstra method but it keeps saying ERROR: Error, query must return columns 'id', 'source', 'target' and 'cost' this is my query: ...
0
votes
0answers
18 views

find nearest point to a point in another table

This similar, but not quite the same as this question. I need to pick, regardless of distance, the closest 'n' points to a given point in another table, using postGIS. Imagine a table with city ...
3
votes
2answers
2k views

PostGIS: Convert meters to arbitrary spatial reference units?

I'm writing a query that needs to be able to work with data of any SRID. The basic problem is very simple - I get two pieces of information: A point (SRID = 900913) A distance (unit = meters) I ...
1
vote
1answer
1k views

Having trouble connecting QGIS with postgres database with postgis extension [closed]

I am working on Ubuntu Precise with postgresql version 9.3 and postgis 2.0. After initially starting my postgres database and eventually getting permission errors that would prevent postgres from ...
1
vote
1answer
62 views

connecting Arc 10.3 to a PostGIS database “the coordinate system identifier is invalid” [closed]

Has anyone had any success directly connecting Arc 10.3 to a PostGIS/postgres database, where the geometry type is 'geometry'? I am able to connect and view the tables, but I am unable to view them - ...
0
votes
0answers
41 views

Why is Geoserver publishing my WMS layer in WGS84, when I have specified WyLAM?

I am trying to publish a WMS layer from Geoserver, based on a table in a PostGIS dastabase. The projection of the original source data is "WyLAM" (EPSG:8155). It seems that no matter which options I ...
3
votes
1answer
51 views

Prevent PostGIS Topology from splitting edges on line insert

I'm dealing with a large amount of road data represented with PostGIS Topology types. Anytime I add an edge over another edge, the edge is automatically split and a new node is created at the ...
7
votes
1answer
49 views

Why is there an upper limit to the SRID value in the spatial_ref_sys table in PostGIS 2.1?

I was trying to insert a reference system in PostGIS from http://spatialreference.org/, and got a constraint violation for spatial_ref_sys_srid_check. I checked that constraint and found that, when ...
0
votes
1answer
41 views

how to insert coordinate of province to postgresql?

i need insert to database this area sample: [ [ [ 50.227886556627098, 31.15709614260982 ], [ 50.227886335531331, ...
0
votes
0answers
39 views

How do I design a database for storing GPX tracks and supporting spatial queries?

I have a series of GPX files that contain 1...n tracks. Each track contains roughly 5k - 10k points. The GPX files do not contain waypoints or routes. I want to design a database with the following ...
11
votes
3answers
8k views

Error when trying to run Create Extension postgis

I have installed PostgreSQL 9.x and PostGIS 1.5/2.0 several times and have never had this problem. I just got a new CentOS 6.3 server up and running and and I have Postgres 9.3 functioning as ...
1
vote
0answers
18 views

Can the correct TIGER Line Id be returned for an address from the PostGIS Tiger Geocoder?

After reviewing the PostGIS Tiger Geocoder documentation, I don't see a method of returning the TIGER Line Id for the address. I would assume this is information is available internally as part of ...
1
vote
2answers
74 views

How to transfer large amount of OSM data to postgis using osm2pgsql?

I am new to using Openstreetmap data and PostGIS database. I learned how to use osm2pgsql and transferred osm data for a small city to PostGIS database and worked fine. The problem is that when I try ...
1
vote
1answer
783 views

How do I resolve “relation does not exist”

I have a view, named PointsForGpxExport, that contains points I want to export to a GPX file. The ogr2ogr command I'm trying to use for the export is included below. When I run the command, a GPX file ...
0
votes
0answers
19 views

map doesnt shown up in css page

I use postgreSQL 9.2, postgis 2.0 and 2.1, pgrouting 2.0, and I connect it with css page (localhost) but the map from pstgreSQL database doesnt shown up, can anybody help me? MAP NAME PADANG # ...
0
votes
0answers
37 views

Publishing Geoserver WMS on Drupal 7 using openlayers module not working

I'm unable to overlay my WMS layer published from geoserver on map. Im using openlayers module in drupal 7 configured with geoserver + postgis. Im using EPSG:3857projection. Also the Geoserver module ...
7
votes
2answers
2k views

Postgis 2.0 upgrade problem with postgres data?

I have a serious problem: on Wednesday, April 2 OpenSUSE 12.1 is updated, and the package was to update the PostGIS-a version 1.5.3 to 2.0.0. After this operation, Postgres does not display records. ...
1
vote
1answer
25 views

geometry_column table not automatically exist

I use PostgreSQL 9.2 but geometry_column table not automatically exist like spatial_ref_sys table, but if I use PostgreSQL 9.1 it's exist. How to make geometry_column automatically exist in PostgreSQL ...
1
vote
1answer
115 views

Why doesn't my spatial index work?

I have a table with 50 million test points. The points are stored as latitude / longitude with SRID = 4326. The create script for the table: CREATE TABLE points ( name character varying, point ...
4
votes
3answers
108 views

How can I export points as GPX?

I have some point data in PostgreSQL / PostGIS. How do I export the data to a GPX file? I looked for commands similar to ST_AsGML and ST_AsKML but could not find anything to convert to GPX (like a ...
1
vote
0answers
64 views

Is there PostGIS equivalent to arcpy.sa.Slice() function?

I have an existing system built on an 8.3 PostgreSQL database which uses a ArcGIS - Spatial Analyst for a couple of raster operations. The system is moving to PostgreSQL 9.2 and I'm evaluating if the ...
9
votes
1answer
174 views

What PostGIS [topology] provided tools may be used for data quality assurance?

I'm learning about techniques to ensure GIS data quality. Googling around, I've found a few papers about theory and best practices (here and here), and a couple of short presentations about the topic ...
1
vote
2answers
40 views

Loading data using QGIS to PostgreSQL database

I am trying to import a shapefile using desktop QGIS to postgreSQL database using the import shape file to postgresql database tool but it raises the following error: Problem inserting features ...
1
vote
1answer
53 views

How do I project a point stored as Lat / Lon to a state system?

I have some points stored as WGS84 (EPSG:4326) data. I want to write a SELECT statement to return the projected values, in EPSG:2811, and unprojected values. Here is my table SQL: CREATE TABLE ...
1
vote
1answer
109 views

Creating GeoJSON from Postgres

We are transitioning from Google Maps to Mapbox. Mapbox is a proponent of geoJSON and uses it extensively, so we are considering adopting it for all of our maps. An issue is the creation of the ...
1
vote
0answers
36 views

Postgis - st_MakeLine and st_lineLocatePoint

Lets explain, I have 4 points (1,2,3,4), and I need to visit clients (A, B, C, D). So, I need to use st_makeline with (1,2,3,4,3)... Now I have to get % position from A,B,C,D; but in visit order. ...
1
vote
1answer
182 views

Unable to create Polygon using Geodjango admin interface

I am new to GeoDjango. I have created Admin interface for my Model. It loads correctly. I am also able to draw the Polygon on map(At client side) but when I save It tells me Invalid input and throws ...
0
votes
0answers
42 views

Add new feature to postgis via geoexplorer

I have a polygon table in postgres/postgis and I set up some fields to not allow null values. My problem is when I add a mew polygon via opengeo geoexplorer (myviewer sdk) and keep these fields empty ...
0
votes
1answer
28 views

problem in PostGIS Name of the system used for Points and how to get distance between to point?

I have started to work on a project in PostGIS. I have a table with a geometry points in which points saved like this : "010100000089F511C671C01E4162327E2A83545341" and I have translated this ...
0
votes
2answers
98 views

Neighbors within distance from every row

I have a research project of 180,000 entries and I need to calculate the number of neighbors (points from the same table) that exist within a 300 meter radius for each point. My method is very slow, ...
0
votes
0answers
12 views

PSQL: Setting maxspeed to all highway tags having 'highway' text= NULL AND 'maxspeed' text = NULL?

Hello everyone, I am trying to create a procedure in postgresql using functions of postgis extensions where I can first search and find all the rows having an empty 'highway' tags AND ...
0
votes
1answer
65 views

OpenLayers WFS-T tinyows insert transaction: error GID value

I try to implement insertion of new point using Openlayers v2.13 saveStrategy calling tinyows which implements the WFS-T transaction; I use the example from ...
0
votes
0answers
17 views

postgis 2.x geometrycollection and multi

I want to gather differents geometries in a table. So I transformed a multipolygon geometry in a geometrycollection. Now if I can insert differents geometries, I lost the capability of insert ...
0
votes
1answer
78 views

How to create buffer around point having projection 4326

I am trying to create buffer (in meters) around point(long lat alt) which is in projection 4326 with below code. But it is not giving expected output. SELECT ...
1
vote
1answer
73 views

How to create Spatial Reference System in QGIS?

I have some Attribute and the coordinate and the coordinate reference system. I want to create a DBmanagamet form my spatial data. To do that I want to create one table with name Spa_ref_sys, but I ...
1
vote
0answers
34 views

Problem with ST_SummaryStats, ST_Buffer, and casting between geometry/geography types

I have a test raster that covers the world ((-180 90), (180 -90)). The SRID is WGS 84 (EPSG:4326). Values for cells in the north-western quadrant ((-180 90), (0 0)) are random integers in the range 1 ...