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

learn more… | top users | synonyms

0
votes
0answers
50 views

populating a geojson from postgresql with php depending on zoom level

i am about to load a few thousand polygons (a grid 500x500m) from a postgresql db into a leaflet map with php script converting the data into a geojson. the php script populates the geojson depending ...
0
votes
0answers
64 views

How to “INSERT” geotiff raster into postgresql/postgis table using psycopg2

Can someone walk me through how to insert a raster into a prebuilt postgresql table? The table has the postgis extension and I've been able to manually insert a geotiff using raster2pgsql, but I would ...
0
votes
0answers
38 views

How to not display a layer, if its below a other semi transparent layer?

I have two polygon layers (PostGIS). One of them is semi transparent. If the other layer is below the semi-transparent one, it should not be displayed. My situation at the moment is: The grey ...
0
votes
0answers
43 views

Replicate routing behavior

I've been dealing with problem for a while now and I want to know if I'm in the right track, basically I want to replicate this site functionality and so far I think it can be done with pgrouting ...
0
votes
0answers
62 views

Interpolate missing M values along a line

Is there some way in PostGIS to interpolate missing M coordinates in a geometry like this? select ST_MakeLine(ARRAY[ ST_MakePointM (0, 1, 10), ST_MakePoint (0, 2), ST_MakePoint (0, ...
0
votes
0answers
46 views

Select points greater than a certain distance from related points based on shared foreign key id

I have a PostGIS-enabled PostrgeSQL db, using QGIS, with data using EPSG:4326, and projected as EPSG:29903. I have a table with points with pk point_id and a table with images with fk point_id. I want ...
0
votes
0answers
44 views

pgRouting adding point or line barriers

In pgRouting can we add barriers (point, line, polygon) to avoid using a road partially not entirely. For example we have point features in another table. Or line features which is sub-part of a ...
0
votes
0answers
50 views

Clipping raster without create new table in PostGIS?

I'm learning about PostGIS, and I would like to create a SQL to cut a raster with a shapefile to work in my R program. I managed creating a new table, but I would like build it without a new table. ...
0
votes
0answers
54 views

pgsql2shp result as shapefile

In addition to pgsql2shp command join error, the next command line works fine in order to join a table to a shapefile but the result is a dbf table and not a shapefile as I want. I see that exists a ...
0
votes
0answers
50 views

PostGIS and QGIS connection using queries?

I have a shapefile and a table which I import both of them to PostGIS. With pgAdminII I am able to manipulate the table, join to shapefile and calculate new fields. When I try to do that with python ...
0
votes
0answers
24 views

returning id's from spatial query

I am doing a spatial query to see if water sensors exist or not in a database. If so I want to return the unique identifier # that exists on the ones in the database so I can match it to the ones ...
0
votes
0answers
29 views

Space Efficiency - Geotiff File VS Postgis Raster

Is it more space efficient to store a raster as a geotiff file on disk or directly in Postgis? I ask because I currently have a large number of rasters stored in a Postgis database and I want to ...
0
votes
0answers
32 views

Different pixel values for a raster between QGIS and PostGIS

I have inserted a Landsat raster into PostGIS using the command : raster2pgsql -I -C -s 28356 -M -t 100x100 /data/LS7_20150425_B40.tif public.red | psql -d postgres -U postgres Using QGIS, I have ...
0
votes
0answers
49 views

Filtering out of bounds' coordinates

I have a set of coordinates, that I receive from GPS. I store them in database, its geometry is 4326. I am using the next query to calculate the travelled distance: ...
0
votes
0answers
79 views

FME autoincrement id is not recognized

I have made a workflow in which I pass some data from a shape file to a postgis database using FME 2015. The table in the database has several columns and one of them is an id with an autoincrement ...
0
votes
0answers
64 views

Importing array directly as raster to PostGIS in memory?

Below is python code I wrote to import downloaded rasters into a postgis table using raster2pgsql. I have a question involving efficiency. Instead of writing the raster to disk after doing array ...
0
votes
0answers
39 views

WFS to PostGIS with Geokettle

I am trying to use Geokettle to write records to PostGIS. Geokettle has has a WFS input step. I cannot get it to work, I cannot find much documentation about it and I wonder if anyone here has used ...
0
votes
0answers
64 views

PHP, PostGIS & Geojson

I'm using Lumen to connect to postgis and I want to execute this query: WITH query AS (SELECT ST_GeomFromGeoJSON('{"type": "Polygon","coordinates": [[[366063.228612569917459, ...
0
votes
0answers
38 views

postgis ST_Intersect on 2 valid geometries throws TopologyException

Using Postgis 2.1 on PostgreSQL 9.3.4, I'm getting an error when I try to intersect two valid geometries: TopologyException: found non-noded intersection... These geometries are created on the fly ...
0
votes
0answers
56 views

Postgis poligonize. How to create polygon in postgis from linestring

I have a problem with the poligonization. I have a table that contains the my borderstones. The second table defines the next and previous point. It is important because these are attribute datas. ...
0
votes
0answers
98 views

JSF2Leaf - JSF page parameters to bean

I'm using jsf2leaf framework to draw trajectories between two markers, like example. I need to send two parameters (id of point) to search possible trajectories between both. At the moment the ...
0
votes
0answers
39 views

Positioning new point on line with OSM routing?

I have three tables: ways_vertices_pgr (from OSM Routing, contains road vertexes I use for creating routes and among other things their geometry), routes (geometry) and a table which holds the order ...
0
votes
0answers
44 views

Receiving -infinity in geoserver wfs GetFeature result

I'm currently using: - Geoserver 2.7.2 - PostgreSQL 9.4.4 - PostGIS 2.1.9 When I submit the following wfs GetFeature request: ...
0
votes
0answers
61 views

Fulltext Search with Spatial Search with pagination

We tried to use postgresql+postgis to save our spatial data with points/lines/polygons. Though the postgresql have a built-in full-text search engine, we have to use lucene for some reasons, and ...
0
votes
0answers
56 views

TileMill / Mapnik with Postgis datasource

I'm having some problems getting a full features (roads, rivers, buildings, parks, etc) map to show on TileMill. The steps I taken so far: Mounted a PG9.4 with Postgis 2.1 database Downloaded the ...
0
votes
0answers
40 views

pgr_dijkstra doesn't return when cost values are low

I'm using a different cost column in pgRouting, and passing it to pgr_dijkstra but it returns 0 rows. I analyzed that column and contains some 0 and values in scientific notation (1e-6) and also ...
0
votes
0answers
59 views

MS4W MapServer 7.0 - Filter error after upgrade from 5.6

First of all I need to say that I'm complete new to this. I've been mandates to migrate a web application (written in Python and using PostGRE/PostGis) on a Windows XP box (!!!) to a more recent ...
0
votes
0answers
67 views

Some geometries don't work with ST_Union and gives a non-noded intersection

I'm getting a lot of errors like this: GEOSUnaryUnion: TopologyException: found non-noded intersection between LINESTRING (147.254 -42.8705, 147.254 -42.8705) and LINESTRING (147.254 -42.8705, ...
0
votes
0answers
20 views

Bounding box path planner

I am looking into postgis to solve path planning problem. If someone could give hint on that matter it would be great. So problem is following: given a specific bounding box, plan route inside box ...
0
votes
0answers
24 views

Add a point inside a polygon randomly

If I have a polygon and a set of points all contained within the polygon. How would I best add a new point to the point set such that:- a) it was contained within the polygon b) it was spaced at ...
0
votes
0answers
47 views

how to get the point's elevation from raster database

I download some *.tif files from http://srtm.csi.cgiar.org/. Then I use gdal2wktraster.py to store them into my postgresql with postgis extension. Args are python gdal2wktraster.py -r *.tif -t ...
0
votes
0answers
50 views

How to import NMF file into PostGIS

I just got my very first NMF file and I am stumped on how to get it into my database. I have been able to handle anything thrown at me so far using either QGIS and ogr2ogr to get my data into PostGIS. ...
0
votes
0answers
23 views

How to edit the coordinates of a feaure in Postgis using SQL

I am using AmigoCloud for data collection and they store info in a Postgis table. I need to edit an existing the point feature using a SQL query. Is it possible?
0
votes
0answers
38 views

Regarding Geoserver postgis Store - connection Issue

I have installed geoserver 2.7 in windows 8.1 Everything works fine but while I try to connect PostGIS store using the GeoServer web admin page I get error as unable to obtain connection. I have my ...
0
votes
0answers
65 views

Postgres PostGIS geocode_intersection()- How to handle exception?

I have a table in Postgres with a set of records that are street names which needs to be geocoded to get an intersection point.Some of the records would be bad input and when using the ...
0
votes
0answers
196 views

Use postgis functions in restful web service java

I am trying to access Postgis functions in Restful web service JAVA. I am using netbeans 8.0.2, Glass Fish, J2EE 7 to create web service, PostGres 9.2 and postgis 2.1.1. Connection to postgres is ...
0
votes
0answers
44 views

Equivalent for PostGIS ST_SnapToGrid in ArcMap 9.3

I'm new with ArcGIS and ArcMap. I need to round coordinates on precision of 2 decimals while maintaining relations between them. So basically I need to make something to be equivalent of ...
0
votes
0answers
51 views

Snapping points to nearest road - query is extremely slow

I have a two tables containing (1) all parishes in Denmark (centroids) and (2) a road network of Denmark (OSM data). I am trying to find the nearest road for each parish centroid. To do this I'm ...
0
votes
0answers
57 views

Postgis reverse geocoding for other countries

I have tried using postgis_tiger_geocoder extension for reverse geocoding and it just has the U.S related data(56 states or so) but I need to have few more countries like canada and few more. Is there ...
0
votes
0answers
20 views

removing point cloud data from PostGIS

I'm ingesting dozens of LAS files into one table in PostGIS using PDAL using the example from pdal.io: <?xml version="1.0" encoding="utf-8"?> <Pipeline version="1.0"> <Writer ...
0
votes
0answers
43 views

PostGIS: Lines from location touches but not intersecting polygons

I have OSM .shp file of buildings. I created vertices along each line of the building in that way: vertices (red) & mid points (green). The mid points made by ST_Line_Interpolate_Point() after ...
0
votes
0answers
178 views

How do I set up a PostgreSQL database for use with PostGIS and GeoDjango?

The Django docs say to use createdb -T template_postgis geodjango but I already have a database set up. While trying to find out what this actually does and a way to apply it to an existing ...
0
votes
0answers
31 views

Can't set cache on tilestache

I've successfully installed tilestache on my server and able to load a geojson from it. But when I change the config file to use disk cache, the server return 500 on requesting the tiles. What I add ...
0
votes
0answers
31 views

PosGIS: Longest line connecting point to line

I have a point and around it lines and polygons in the rule of obstacles. I want to connect the point to each of the lines, with a line, such that this connecting line is not intersect any obstacle ...
0
votes
0answers
31 views

GeoWebCache Speed SQL Server Store

How to increase GeoWebCache speed, Am using geoserver 2.7.2 for tile cache and data store creating from a SQL Server database it will take 1 day and above to complete cache and it terminated several ...
0
votes
0answers
21 views

how to use st_intersection() with re-projection in POSTGIS?

This is a shipping route from 'portland to busan' and I want to check the route against land_polygons like how much distance is traveled by a route through land.And the problem is while checking the ...
0
votes
0answers
76 views

collada2pgsql: importing 3d models into postgis

I have been researching for a tool (open source) for importing collada (.dae) file into postgis and i have found this collada2pgsql command. I really don't know where to find it but it seems to be ...
0
votes
0answers
54 views

Aggregate/merge data upon insert into PostGIS (via gdal)

I am working on a project where I take a large raster file (1.5GB+), put it through a number of image-processing operations, and finally convert it to vector data. Being that the raster is large, I am ...
0
votes
0answers
43 views

To find a substring of a linestring in postgis to be used in playback in map

I have gps coordinates as point outside the linestring/road. I have interpolated to the closest point in the line using ST_Line_Interpolate_Point(). Now I need to draw line through these points and it ...
0
votes
0answers
103 views

How can i create a table in pgAdmin using python?

i am using below SQl query in python cur.execute('''CREATE TABLE Ambhara_Survey (id SERIAL PRIMARY KEY, geom geometry, chalta_no TEXT, ror_area TEXT, ...