PostgreSQL is an open source object-relational database system.

learn more… | top users | synonyms (1)

15
votes
5answers
14k 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 ...
0
votes
0answers
32 views

How to query Tiger Data for Layers?

I am new to this. I have data downloaded from ftp://ftp2.census.gov/geo/tiger/TIGER2015/ and I would like to learn more about how I can query that data for the different layers it offers. Here is ...
1
vote
0answers
24 views

Operations in 3DCityDB [closed]

I am working with CityGML model, I've already put it in the 3DCityDB(postgres/postgis). What I need to know is, how to make a basic operations e.g. spatial join with some another layer etc. I know it ...
2
votes
1answer
40 views

coordinates point in any reference system

I have a coordinates point like this "01010000003413056727B71D41C7F1A68B1ADC4141", but I don't know it is what. Can you aswer What is this?
0
votes
1answer
37 views

Relate two tables based on geom

I have a problem, which is, I have a table ways (like in the Workshop of pgRouting) and I also have a different table street_name, where it contains the name of the street (among other information). ...
2
votes
2answers
70 views

How to select 200 random points within a 100m radius in Postgis

I'm currently learning to use PostgreSQL and PostGIS. I would like to know how to write the SQL that would allow me to select 200 random points within a radius of 500m from a user defined centre ...
2
votes
0answers
27 views

Overlapping line aggregation+trim in PostGIS, while summing values

I'm sorry for the vague title, I didn't really know how to name this. I am working on a project that visualizes and simulates 17th century trade. For this project we also use so called Minard lines to ...
4
votes
1answer
56 views

Weighting amount of overlapping polygons in postgis

I have two tables that I join in my existing workflow. One of these includes flood events (was a shapefile that has been imported to PostgreSQL), the other one is a grid that holds the amount of ...
1
vote
1answer
52 views

postGIS, length, area, density of line network

I am trying to figure out the length and density of all major roads and minor roads within a study area to return something like: ...
1
vote
1answer
51 views

Get addresses from TIGER geocoder in polygon

I have the TIGER geocoder installed, setup and working in POSTGIS. I also see the reverse geocoder lets me get an address from a point on the map. But now I want to provide a polygon and get all the ...
1
vote
1answer
38 views

raster2pgsql size problem

I am about to import a raster (.tif with 50mb, size 3301x21676, pixel size 10x10) into postgres with raster2pgsql. With small extracts of the image it works but ... raster2pgsql [myfilename].tif -F ...
6
votes
2answers
200 views

What controls the direction of TopoGeometry Linestrings?

In PostGIS, what if anything controls the direction that topogeometry LINESTRINGs will have when converted to geometry? It doesn't appear to be the order in which the edges are listed in the call to ...
2
votes
1answer
372 views

Convert native box to geometry

I have an old table that contains bounding boxes of lat long coordinates in a "box" type. How do I convert them to PostGIS geometry ? I tried using ...
16
votes
5answers
6k views

Working with PostGIS data in R?

I work with R almost all the time, and now I am using it for doing spatial data mining. I have a PostGIS database with (obviously) GIS data. If I want to make statistical spatial analysis and plot ...
1
vote
0answers
22 views

Read latitude/longitude to create new point grid at higher resolution

New to SE, needed to reformat my other question. Basically I'm looking at reading a CSV with longitude and latitude points (in this case housing exposure, simplified below): HUC4,Longitude,Latitude ...
-1
votes
2answers
55 views

Publishing Map on ArcGIS Server Manager without using ArcGIS for Desktop? [closed]

I want to publish my maps on sever manager. My map data is in PostgreSQL and I want to connect it without using ArcGIS Desktop. Is there any possibility to publish service without involving ArcGIS ...
8
votes
2answers
2k views

ArcGIS 10.1 edit PostgreSQL layer

I've been working with QGIS/PostgreSQL/PostGIS for a while now, without problems. But now I have to change QGIS for ArcGIS 10.1. I'm having trouble adding a layer from PostgreSQL and being able to ...
11
votes
2answers
3k views

How do I check which version of GDAL I have and how many?

I have installed in my computer the following software: PosgresSQL 9.3.2.3 PostGIS 2.1.1.1 QGIS 2.0.1 Dufour (this one installed through the OSGeo4w package) QGIS 1.7.0 Wroclaw As far as I know ...
0
votes
1answer
64 views

postgis/postgres ST_Distance and GROUP BY

Trying to find the nearest road to a postcode point and order the results by distance. The roads are named according to UK convention so A606 etc and there are multiple entries for many road numbers ...
4
votes
3answers
2k views

Publish SQL Views from Postgres/Postgis to Geoserver

I've trying and reading how to publish a Postgres/Postgis View in Geoserver. I know that I can create an SQL View in Geoserver, but I'd like to define the View in Postgres, not in Geoserver. Does ...
0
votes
1answer
35 views

Service Definition File (.sd)

Is there any possibility to make a SD file without using ArcGIS Desktop? I have to upload my service on a service manager and I am using PostgreSQL as a database.
2
votes
1answer
47 views

Group by Location within N Meters in PostGis

In PostGIS, given several Location objects, each of which looks something like this: { :id => 1, :latitude => 32.4196, :ll_point => "(-10111.1877176122, -5384086.44077608, ...
4
votes
1answer
128 views

Insertion of a raster geotiff in PostgreSQL database

I am new in PostgreSQL and psql. What is the method to insert a raster geotiff in a postgreSQL database using command psql? What is the best format? Someone indicates to save a raster image as BLOB ...
0
votes
1answer
50 views

OpenGeo Suite 4.0.1 Activating SSL for remote connection

I have installed OpenGeo Suite 4.0.1 on my Windows 7 OS and created a spatially database. Now i want to connect to my database remotely but then it seems like i have to generate a self-signed key. i ...
1
vote
0answers
40 views

Updating an Openstreetmap PostgreSQL database after the system restore

My Openstreetmap PostgreSQL database takes a long time – about 25 hours by now – for updating via Osmosis after I had made a system restore at the last weekend. Before making the system restore it ...
3
votes
0answers
41 views

Layers created by GeoServer do not display in Mapbender3

I have installed GeoServer 2.7.2 on my local windows 7 machine, which retrieves data from a remote PostgreSQL server. The data is represented in layers just fine! I also have installed Mapbender3 ...
2
votes
1answer
215 views

PostgreSQL PL/Python Function for “IF” condition

I am using OSM data to run pgr_dijkstra() for weighted-path calculation. But after importing OSM data using osm2pgsql I populated some additional columns into my ways table. So now it has gid serial, ...
1
vote
0answers
73 views

Installing Aggregate Polygons Function in PostgreSQL 9.3

I'm new to PostgreSQL and I've been trying to run a sql function written by Dr. Horst Duester, found in http://www.kappasys.ch/cms/index.php?id=65&L=5, which is used to aggregate detached ...
4
votes
2answers
265 views

How to use interacting PostgreSQL/PostGIS triggers in QGIS?

I use point geometries (table 'label_point') to place multiple labels on polygon geometries (table 'soil'). After doing layer edits I've to update the affected label_point features. Therefore I've ...
1
vote
1answer
37 views

Multiple queries in pgrouting (length as result)

I am facing the following problem with two tables: The first table contains all my streetnetwork with cost, source, target. Another table contains 60 nodes (from the above network). Between all ...
7
votes
1answer
209 views

Calculate mean value of polygon from raster in PostGIS

I started with a NetCDF .gri and .grd raster file of the UK provided by a colleague. I clipped it in R to be only London, exported and converted to a ASC file, and then imported it to PostGIS using ...
1
vote
0answers
53 views

ESRI/SRID mismatch: How to correct?

I'm currently working with PostgreSQL and CartoDB to display X and Y coordinates converted to a geom. My shp files have been created and are displayed through CartBD. When I try and run a map view, ...
2
votes
0answers
35 views

Enumeration in QGIS

When I am using QGIS 2.8.3. I want to use a series of predetermined set of texts, such as 'wood', 'brick','concrete'. I have created an enumeration file in SQL, I do want to link that my existing ...
2
votes
2answers
43 views

Distance between sequential points postgre

My table is as follows 1;"2015-10-02";"POINT(lat,lon) as geometry" 2;"2015-10-03";"POINT(lat,lon) as geometry" 3;"2015-10-04";"POINT(lat,lon) as geometry" How can I find the distance between two ...
0
votes
0answers
231 views

How connect C# to Postgresql in host j.layershift.co.uk

I have installed postgresql database in http://postgres-project-1241043.j.layershift.co.uk/ host. I want to connect to the database using C#. I use Npgsql with following connection string. ...
1
vote
1answer
33 views

Is there any site where I can found city shapes in postgreSQL polygon format

Is there any site where I can found city polygon area (for postgreSQL or similar)? I don't know if such resources exists, and I don't know how to find it.
1
vote
1answer
481 views

osm2pgsql cannot connect to postgis database, running on a Bitnami project installer

Based on this guide I am trying to import an .osm.pbf file into my PostGIS database, which is running on my Postgres Bitnami installation here: [bitnami@ip-xxx]/usr/share/proj$ which postgres ...
0
votes
1answer
40 views

postgresql out of memory [closed]

I clip 70 raster with polygon in postgresql, the result are: out of memory, Fatal on request size of 10872 I read some solution about changing the postgresql.conf parameter but nothing work for me ...
1
vote
0answers
63 views

Importing tif image from PostgreSQL Database to webpage

I am trying to import tif images from PostgreSQL Database to my website. In the website, I need to make a button control which will open the images. I think I have to use Python as a server side ...
1
vote
1answer
57 views

PostgreSQL is refusing connections from MapServer

I have MapServer 6.04 running in Centos 6.7. I am able to server shapefiles and GeoJSON, but when I try to connect to a PostGIS (2.1.8) enabled PostgreSQL (9.4.5) database it fails with the error: ...
0
votes
1answer
48 views

How do I create and manage custom SQL functions in CartoDB?

I'm working through a CartoDB tutorial at the moment, and got to the point of creating a custom SQL function. Do I just write this in the "CUSTOM SQL QUERY" Field on the right of my table? How do ...
1
vote
1answer
53 views

Inserting spatial data into existing postgis geometry column from shape file based on ID

I have an existing postgresql database table "city_data" with Non-spatial data in the following format: City_ID as varchar, City_name as var_char, pop as int,.... I have enabled the postgis ...
1
vote
1answer
42 views

Deleting records from table where ST_DIstance from another record in another table is greater than a certain amount

I'm currently learning SQL on the run, and have come across a situation where I'm trying to delete records from a table depending on a function result. I can select the records of interest with the ...
1
vote
1answer
34 views

How can I count points from several buffer distances in PostGIS updating the table?

I have a problem regarding a calulation on PostGIS. I have to calculate how many facilities fall within a given distance. This is not really a problem though, but updating my table is. I have this ...
2
votes
1answer
104 views

How to use ST_DWithin to query features from one table within a distance of a specific feature or features in another table

I'm pretty new with PostGIS. I have a parcel layer and a census block layer in a postgres database, and I would like to be able to query out all census blocks within a specified distance of a specific ...
1
vote
1answer
42 views

Intersection of two vector tables data in postgresql

I have satellite raster data that is converted into pixels using CREATE TABLE gtru_tile_pix AS SELECT (ST_PixelAsPolygons(rast)).val, (ST_PixelAsPolygons(rast)).geom FROM gtru_tile_raster; ...
2
votes
0answers
33 views

Efficient processing of ST_ValueCount Results in Postgresql

General Problem: I have a table of rasters. The rasters are classified MSI images, so each pixel is an integer indicating the class of the pixel. For a number of regions, I am querying pixel counts in ...
6
votes
2answers
179 views

How to do a spatial join in PostGIS that returns on the minimum value of point intersecting polygon?

I have a polygon table (buffer) and a point table (dem_points), and I want to do a spatial join on them. I need to join the point with the minimum elevation (dn) to its spatially corresponding ...
2
votes
1answer
44 views

How to find records using a distance filter, in a table of Points?

My table fields are: POSIC (id, geom, dt_inclusion). DB is PostGIS. Data comes from a GPS Source, then i can create a route ordening the points by Date_Inclusion. So, lets say i have registries A,B,C ...
0
votes
0answers
32 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 ...