PostgreSQL is an open source object-relational database system.

learn more… | top users | synonyms (1)

5
votes
2answers
589 views

How to add sfcgal to an already postgis enabled database

I have a postgres 9.1 database with postgis 2.1, and I recently needed to add sfcgal to it, so i rebuilt postgis 2.1, but I can't find out how to update the postgis extension in postgres without ...
2
votes
2answers
118 views

QGIS Web Client - postgreSQL Layers wouldn't shown

since updating my QGIS to version 2.8.3 the postgreSQL Layers wouldn't shown in the QGIS web client. In the Desktop version the project works very well I only can see the projecttitle and the groups ...
0
votes
2answers
861 views

I have not found shp2pgsql in postgis installation

I have been installed postgis following this guide. All is OK. SELECT postgis_full_version(); "POSTGIS="2.1.7 r13414" GEOS="3.4.2-CAPI-1.8.2 r3921" PROJ="Rel. 4.8.0, 6 March 2012" GDAL="GDAL 1.10.1, ...
1
vote
1answer
60 views

Join two tables completely on geometry (postgis)

I have two tables with the same street network as geometry (but not a same id). What I want to do is to join both tables with all attributes to one for all geometries which overlap exactly. ...
1
vote
0answers
44 views

refine nearest_node with radius-distance ( ST_Distance, ST_DWithin )

i am a hobby-IT-person and currently stuck with some simple problem, maybe somebody can help me: This is my working POSTGIS-function, source by underdark: ALTER TABLE distance_graz ADD COLUMN ...
1
vote
1answer
124 views

How can I render the postgis layer to the openlayers map viewer?

I have a postgres table which is storing the dynamic GPS point data. The geom column has been created. Is it possible to render the last 10 mins GPS data to the OpenLayers map? Is there an example?
2
votes
1answer
59 views

Interpolating mobile signal data

I have collected the signal strengths for the mobile operator at some places in my college campus. Now I want to spatially interpolate this data for the entire campus. I am using PostGIS. I am ...
2
votes
0answers
27 views

Creating lines from lonely nodes in a linestring table to closest point on another linestring table

I want to segmentate a country (denmmark) by using barriers such as larger roads, railroads and the border/ coastline as the delimiting lines of the polygonise function in QGIS. But as most roads and ...
0
votes
1answer
37 views

How to identify the right road using postgres and postgis

I want to identify a road at particular point of intrest using post gis. Example Input String : 16th cross near xyz mall. Problem I am facing As there will be many "16th cross roads" in the map , ...
5
votes
2answers
343 views

Counting self intersections of linestring using PostGIS?

Is there a way of using PostgreSQL + PostGIS for finding the number of self intersections in a linestring? I have a linestring that goes forward but in circles, and I need to find the number of times ...
2
votes
0answers
39 views

Changing border style in OpenStreetMap?

I am trying to figure out how to change OpenStreetMap country borders color/thickness. I've set up a tile server using OSM data, PostgreSQL & Mapnik. The default mapnik style is used. There ...
3
votes
2answers
211 views

Is there a way to change ST_asGeoJSON return values?

The function ST_asGeoJSON returns something like: "st_asgeojson": { "type":"MultiLineString", "coordinates":[ [ [-3.13512629299993,39.7174353130001], ...
3
votes
2answers
80 views

PostGIS does not find intersection between line and polygon

I have a line and polygon: I would like to programmatically figure out whether they intersect or not. So, I do: select ST_Intersects ( ( select ...
1
vote
1answer
230 views

How to get a distinct pair of column values based on minimum of another (computed) column?

I have two tables with point geo data, one (sfc_obs) with weather stations (names), one (smos_grid) with satellite pixels (dggs), and I'm trying to find which dgg is closest to each name using ...
0
votes
0answers
30 views

Number of rows returned via `shp2pgsql` for a given shapefile

With the shp2pgsql tool, I see it converts a shapefile into a SQL statement. Upon closer examination, does the SQL generated ALWAYS contains 1 insert statement for 1 row? Or are there instances where ...
1
vote
1answer
28 views

counting values in an update statement postgres [closed]

I have a repetitive method I want to execute and I expected underneath script to work. I found out the count() function is not allowed in postgres update statements. What is the most logical and ...
6
votes
2answers
3k views

Direct connect to PostgreSQL without ArcSDE? [duplicate]

I have postgreSQL installed on my machine.My machine already has ArcGIS 10. No Sde installed. Can we create geodatabase in PostgreSQL with out installing ArcSDE? Jay Cummins is right. I am intended ...
1
vote
1answer
54 views

OpenStreetMaps: what are the !pixel_width! and !pixel_height! in the queries

The Github repository containing the CartoCSS styling for the OpenStreetMaps dataset also defines queries for the different layers (see this file). An example of such a query is SELECT way, ...
0
votes
2answers
40 views

Finding vertex in comon with most polygons in PostGIS?

I have a table with polygon geometry, in this case representing counties. I'm trying to figure out how to write a query that returns vertices sorted by the number of polygons that share that vertex. ...
0
votes
0answers
35 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: ...
1
vote
0answers
25 views

PCA on correlation matrix in PostgreSQL

Does anyone know how to perform PCA using PL/pgSQL in a PostgreSQL function, considering correlation matrixes of potentially high order? Maybe a specific library for this problem... Thanks.
1
vote
1answer
43 views

Applying OSM z-order after osm2pgsql with qgis

I've trying to find a solution to applying the OSM z-order in qgis after using osm2pgsql. Everything is working perfectly, until I add the each layer to the canvas, where the z-order is not being ...
0
votes
0answers
43 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 ...
1
vote
0answers
51 views

Gisgraphy importer crashing, possibly due to JDBC connections problem. Is there a fix? [closed]

I've been trying to install gisgraphy for the past few days. The setup has went well, but the software crashes while importing data. I'm only importing data for a single country so it's not overly ...
3
votes
1answer
145 views

Postgres, loading raster into db and visualize with qgis

I'm trying to import a TIF raster into a Postgres db using this command: Raster2pgsql -s 26591 -I -C -e -Y -F –N -M C:\Users\Ivn\Desktop\Postgre_HOME\scratchmres1.tif -F | psql -U postgres -d ivndb ...
1
vote
0answers
49 views

raster2pgsql stops at line 53 at RETURN

I am importing some very large rasters (in the tif format) into Postgres SQL (9.3) using raster2pgsql on the command line. Most of the rasters imported fine, some had to be converted to the img format ...
1
vote
1answer
28 views

PostgreSQL - PostGIS linkup error

I have a database that I viewed in QGIS using PostGIS. I managed to link them up using the correst host, database combination last year. I am now revisiting the work and am unable to link them ...
1
vote
1answer
54 views

PostgreSQL equivalent of ArcGIS “Eliminate” function?

I am looking to eliminate small slivers in a shapefile dataset using PostgreSQL. What would work to dissolve features < 0.1 hectares into the neighbour with the longest shared boundary (1) or the ...
2
votes
2answers
918 views

Configuring SFCGAL to PostGIS Db

I was using PostgreSQL with PostGIS and Pgrouting. Recently I needed to install SFCGAL for some extra functions for my PostGIS db. After installing SFCGAL, now I don't know how to update my PostGIS db ...
1
vote
1answer
36 views

Keep empty GRID Cells in PostgreSQL (after join)

I want to join a 100*100m Grid with a point layer. The points contain the number of people living in the grid cell. There are some cells with no polulation, which I want to keep with the Attribute ...
0
votes
0answers
36 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 ...
1
vote
2answers
238 views

Enlisting all OpenStreetMap (OSM) street names for General Transit Feed Specification (GTFS) routes?

I have exported OpenStreetMap (OSM) data of a city to my local postgresql db using osm2pgsql. I would like to add the General Transit Feed Specification (GTFS) routes information (say bus routes) ...
1
vote
2answers
77 views

Edit Geometry with digitizing tools in QGIS of a postgis layer

I have a multiline PostGIS layer added to my QGIS 2.10.1 Pisa. I'm able to add features using the digitizing tools, but I'm not able to use the delete or node tool. It remains gray even if I'm in ...
2
votes
1answer
118 views

Installing Postgis 2.2.0 on Windows?

I'm trying to get the newest version of Postgis (2.2.0) up and running with Postgres 9.4. I'm using Windows and the only installation manuels I found, are Linux-only. Can anybody point me in the ...
2
votes
2answers
102 views

Postgis ST_Intersects performance

I am selecting a lot of polygons within a gigantic polygon by using the postgis function ST_Intersects(). SELECT * FROM data.polygons AS poly, data.gig_polygon AS gig ...
0
votes
1answer
36 views

Using ST_Extrude in Postgres 9.2, with PostGIS 2.2.0

I'm trying to use the function ST_Extrude() in Postgres 9.2. I enabled the PostGIS 2.2.0 extension and the PostGIS_SFCGAL extension (which carries the ST_Extrude function). I can see the function in ...
0
votes
1answer
26 views

How Update one table row with combare with the other polygon table using their geom in SQL Server

a-> points b -> Polygon i want to update city trow in table a with compare b of geom in SQL server this is the PostgreSQL Query update a set city=b.name from b where st_contains(b.the_geom, ...
0
votes
1answer
41 views

Error in using 'psql' from osm2po [closed]

I am following this direction to make network dataset from OSM data to use ArcGIS network analysis (by using osm2po and psql)(http://revenant.ca/www/postgis/workshop/loadingdata.html). So far so good ...
1
vote
1answer
45 views

How to make a change in the_geom_webmercator visible in the_geom in CartoDB?

I am having some trouble with the the_geom column and the the_geom_webmercator column in CartoDB. I have some SQL (which I modified from http://bl.ocks.org/andrewxhill/8695515) in which the ...
2
votes
1answer
17 views

Multi-string data-set without z layer, applying ordinal values as a workaround

I'm new to GIS and have been learning a lot over the last few weeks, however, I've finally come to a point where I could use some help. I'm working with the pdx_streets data-set from ...
0
votes
1answer
152 views

Install Postgresql / Postgis with SFCGAL

I need to access ST_StraightSkeleton() function. At the moment i have a Postgresql instalation PostgreSQL 9.3.4 compiled by Visual C++ build 1600, 64-bit installed via EDB with Postgis 2.1.7 on a ...
0
votes
0answers
89 views

Defining 'os' in geonode custom installation?

Can any body teach me how to resolve this GeoNode problem? I tried following Geonode's documentation on installing it in development mode which was successful however when I tried changing its default ...
2
votes
0answers
38 views

How to clean the postgres instance while setting cartoDB locally in ubuntu

I am following https://github.com/danseely/cartodb-install/blob/master/DEV-INSTALLATION.md for setting cartoDB locally in ubuntu12.04. While installing cartoDB-postgresql, the second install check of ...
4
votes
0answers
246 views

PostGIS 2.0 st_geomfromgml using LineString fails with invalid GML representation

I am attempting to insert a geometry into a table using the st_geomfromgml function. The GML is being sourced from a Geoserver WFS request. The function call looks like this ...
5
votes
0answers
190 views

How do I simplify the straight sections of (multi)Linestring in PostGres/PostGis leaving the curved sections untouched

I have (multi)linestrings containing upwards of 5000 points and I want to perform two simplifications possibly using Ramer Douglas Peucker or alternative methods in PostGis The (multi)linestrings ...
5
votes
0answers
98 views

How to speed up simultaneous working with PostGIS layers in QGIS?

we are working on one big layer at the same time (10-20 people). Some of us use QGIS 2.8.1 and the other 2.6. The user with 2.8 have a lot of crashes (QGIS). The 2.6 users don't have this crashes but ...
0
votes
1answer
222 views

Configure GeoNetwork with postgreSQL

For testing purposes, I deployed geonetwork 3.0.1 on tomcat7 and ubuntu 14.04 with default configuration, especially h2 database. Now I wanted to switch to postgres and followed the instructions ...
2
votes
0answers
72 views

How to export ESRI Geodatabase format .gdb from PostGIS

I found several posts explaining how to import a .gdb file into PostGIS. Is exporting also possible? For example using ogr2ogr to generate a .gdb file from query result.
2
votes
1answer
126 views

How to save postgres table to kml without losing attributes using python

I am saving the postgres table loaded in QGIS to kml. qgis.core.QgsVectorFileWriter.writeAsVectorFormat(aLayer, myFile, "ogr", projDest, "KML") But the output file does not have the attributes. So ...
1
vote
1answer
76 views

Load the postgis layer/table to qgis canvas using python

I want to load the postgis layer to qgis canvas. I am using the following code but it is not loading the layer in canvas. sql = "(SELECT * FROM table WHERE id = 20)" uri = QgsDataSourceURI() ...