Tagged Questions

PostgreSQL is an open source object-relational database system.

learn more… | top users | synonyms (1)

1
vote
1answer
57 views

How to connect ArcMap 10.0 query layer to a different port?

I have an instance where I have a server that has postgres 8.3 and postgres 9.2 on it. I have the 8.3 version on port 5432 and 9.2 on port 5433. I want to connect to the 9.2 instance, here is a ...
2
votes
1answer
601 views

Add PostGIS spatial functions to a custom schema other than “public” in PostgreSQL

I am new to PostgreSQL and PostGIS. Recently, I created a PostGIS 2.0.3 database on a PostgreSQL 9.1 database server using pgAdmin. The "PostGIS" extension was found installed in "Extensions". Al ...
3
votes
1answer
316 views

Python Postgres Multiprocessing speed increase

I'm trying to speed up my PostGIS queries using multiprocessing. My current setup is using python and psycopg2 such as below. Although this has given a speed increase, it still seems like there are ...
1
vote
1answer
237 views

How to get mouseposition (openlayers) in decimal degrees?

I want to display the mouseposition in Degree Decimal rather than in meters. See my code: <script type="text/javascript"> var map, ia_wms; function init(){ map = new ...
3
votes
1answer
2k views

Loading Shapefiles into PostGIS using shapefile import/export manager

I am a complete beginner with PostGIS. I've started learning it using the tutorials provided by Boundless. In section 4 of this tutorial where I want to import shapefile in PostGIS, I do not have the ...
0
votes
0answers
126 views

PyQGIS + PostGis: FATAL: sorry, too many clients already

I searched for questions regarding this problem and hadn't find one. I'm developing a custom application with a map canvas to show some geographic information from a PostGis database. After some ...
2
votes
1answer
75 views

How to properly establish a PostgreSQL connection using QgsCredentials

I'm trying to establish a Postgres connection using QgsCredentials as described here: How to access user credentials in database connection? The only problem is that I cannot establish a working ...
0
votes
0answers
12 views

Prepare OSM file for PGROUTING use [duplicate]

Well I am new in the GIS World :p well I have a webGIS to realise and I want use OpenStreetMap. well the region I need wasn't vectorised so I modified it with JOSM ( Added Roads and buildings) and ...
0
votes
1answer
44 views

Is it possible to render POIs/landmarks from Postgres/postgis DB using google Map like icons?

Is it possible to render POIs/landmarks from Postgres/postgis DB using google Map like icons? Any readily available icon sets?
1
vote
2answers
926 views

How to perform SQL queries and get results from QGIS python console?

I'm writing a python script using QGIS API. I have to get results from postgres database table. The table has geometry field and other non-geometry fields. I want to perform SQL queries on ...
0
votes
0answers
26 views

OSM DataImported in to Postgres: What is the significance of “_gen0” and “_gen1” suffixed tables

Imported .OSM file to postgres/postgis (IMPOSM). Along with the table "osm_new_motorways" I see two more tables "osm_new_motorways_gen0" and "osm_new_motorways_gen1". Same is there for few other ...
-1
votes
1answer
40 views

Qgis 2.0 and conection with Postgres 9.3.2 [closed]

I tried conection with Qgis 2.0 with Postgres 9.3.2 but I was unable to do it. Is there anyone that help me Tks
3
votes
1answer
138 views

User locking postgres/postigs table without privileges

I have a PostgreSQL 8.4.4 database with PostGIS 1.4.2 and I am experiencing a problem where an external GIS system (using embedded CadCorp SIS 7.0) is connecting to the database and taking Access ...
1
vote
0answers
53 views

Reading lines within Bounding box failed

I am developing an application to display OSM data. In my scenario I need to display the data for one entire country. So my approach is that I will load curresponding countries osm data to postGreSQL ...
5
votes
2answers
372 views

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

I have installed in my computer and running 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 I am ...
1
vote
0answers
57 views

PostGIS replace view crashes PostgreSQL server from ArcGIS script

I have the following script which when from ArcGIS (and a similar script from a QGIS plugin) will update a view. Every so often (around 1 in 5 times the script is run) it causes the PostgreSQL ...
2
votes
1answer
346 views

Multipoint vs point PostGIS

Is it normal to use the geometry type 'multipoint' instead of 'point' knowing that I use it to store only one point. How can I convert from multipoint to point
1
vote
1answer
129 views

Lost relation when importing from OSM to PostgreSQL with ogr2ogr

I am currently trying to import all administrative boundaries (countries, states, cities, etc) from OSM. I downloaded a small file from Geofabrik (Corsica), in order to run my tests. I understand ...
0
votes
2answers
51 views

how to specify -t critical dowloading raster with raster2pgsql

I'm trying to download a raster into postgres/postgis. So far I wrote: raster2pgsql -s 3006 -I -C -M -R filename.tif -F -t 463.313x463.313 schema.rastername | psql -h localhost -U postgres -d db ...
3
votes
2answers
181 views

Distance between Paris and San Francisco with PostGis (out of range coordinates?)

SELECT ST_Distance(gg1, gg2) As spheroid_dist, ST_Distance(gg1, gg2, false) As sphere_dist FROM (SELECT ST_GeographyFromText('SRID=4326;POINT(37 -122)') As gg1, ...
0
votes
0answers
52 views

Publish rasters stored in PostGreSQL with GeoServer [duplicate]

we are trying to publish some raster images stored in our Postgres database. First, they were generated from satellite images (spectral indexes). Then we uploaded them with raster2psql as tables. So ...
4
votes
2answers
362 views

clustering points in postgresql to create contour map

UPDATE: To try to make this a little more simple, is it possible to create a query which selects a group of points such that each point in the group is at most X units away from at least one other ...
0
votes
1answer
105 views

Can't create view in postgresql

I have a PostgreSQL table containing some point of interest data. I have a second table with overlapping continent polygons. The following code splits the POI into the continents, but instead of ...
-1
votes
1answer
179 views

Shortest Path Dijkstra

I would like to calculate the shortest path with dijkstra algorithm. sample query SELECT seq, id1 AS node, id2 AS edge, cost FROM pgr_dijkstra(' SELECT gid AS id, ...
0
votes
1answer
96 views

How to cut/split multipolygon with blade (linestring) into two pieces using PostGIS? [closed]

I struggle to do split operation in postgis I tried to build a query but Im always fail. Id like to cut a multipoligon with a blade (a linestring) into two pieces. These two objects have specific ...
3
votes
1answer
285 views

Importing multiple shapefiles into single PostGIS table

I have a folder full of shapefiles that I want to import into a single PostGIS table. This table should have the following columns: id, filename, multipolygon I can bulk import all shapefiles using ...
3
votes
1answer
502 views

PostGIS intersection function

I have a problem with intersection function. I built my query following http://manual.linfiniti.com/en/postgis/geometry.html, 5.7 section. I made my clip object, a red linestring frame: But after ...
1
vote
1answer
175 views

Error: Coordinate values are out of range [-180 -90, 180 90] for GEOGRAHY type on Postgis?

when I run a query on Postgis select st_astext(ST_SetSRID(f.geom,4326) ),st_astext(st_centroid(ST_Transform(b.wkb_geometry,4326))) from a,b where ST_Distance_Sphere( ...
0
votes
2answers
1k views

PostgreSQL function does not exist

I have PostgreSQL 9.2 with Pgrouting extension, but when I want to call a function(pgrouting) does not work. Id like to compute the shortest path between two point. SELECT gid, AsText(the_geom) AS ...
1
vote
0answers
291 views

pgrouting php problem “pg_fetch_result(): Unable to jump to row 0 on PostgreSQL result index 3”

I'm trying to build a simple routing web-app using pgrouting, followed some tutorial and the latest workshop. Because I'm using PostgreSQL 9.3(x64), Postgis 2.1.1, and pgrouting 2.0 so I did some ...
2
votes
1answer
185 views

Case insensitive CQL-OpenLayers filter?

I have the following filter in OpenLayers 2.13 var filter_c = new OpenLayers.Filter.Comparison({ type: OpenLayers.Filter.Comparison.LIKE, property: 'p_name', value: ...
0
votes
0answers
44 views

How to force dropping a table/Index

I was working to import CSV Files into PostGres. CREATE TABLE NY(Name varchar,Latitude float,Longitude float); COPY NY FROM 'data/NY.csv' DELIMITERS ',' CSV; ALTER TABLE NY ADD COLUMN gid serial ...
3
votes
1answer
133 views

how to snap two line vertex in two different layers used in QGIS

I want to snap between two poly-lines from 2 different layers (Layer1 in Brown and Layer 2(postGIS layer) in Pink color- ), but my snap option don't work. I have changed the tolerance to different ...
0
votes
0answers
434 views

Indoor mapping with floor plans and item(s) to track

Warning: GIS noob here. Essentially I want to be able to create a floor plan for a given room. Consider the following image of a floor plan in image format: I would have the measurements of every ...
0
votes
1answer
56 views

Unsure what to do after running osm2pgsql

I must admit that I'm a noob when it comes to database administration, but I'm a little confused at the process of my getting my .osm.pbf file into tilemill. I've run the osm2pgsql process on a ...
1
vote
5answers
579 views

Problem installing PostGIS on Ubuntu Server 13.10

I've installed PostgreSQL 9.1 and postgis on Ubuntu Server 13.10 as follows: sudo add-apt-repository-ppa:ubuntugis/ubuntugis-unstable apt-get update apt-get install postgresql-9.1-postgis then I ...
0
votes
1answer
117 views

Does ora2pg support the SDO_GEOMETRY spatial type?

I've been searching the net up and down for days now and can't find a definite answer to this question, neither on google nor on the official page (http://ora2pg.darold.net/). Does ora2pg support ...
4
votes
2answers
587 views

SQL Syntax to extract (convert) Strings with Degrees Minutes to Decimal Degrees

I have a PostgreSQL/PostGIS database with a two string fields containing Lat and Long coordinates in degrees and decimal minutes, like this 45° 24.5' N 3° 43.01' E. How can I convert them into ...
0
votes
1answer
107 views

How to display data from multiple layers in OpenLayers? [closed]

I am new to using openlayers and Geoserver. I currently have a few shapefiles of a place with a background map of that place. I have imported both shapefiles into postgresql and geoserver. After ...
4
votes
1answer
233 views

POSTGIS SQL - How do I remove (defined) sliver polygons

I would like assistance in writing SQL (for POSTGIS in postgresql) to remove sliver polygons (including long narrow slivers and some small irregular polygons that were erroneous 'gaps' in the original ...
5
votes
1answer
231 views

Spatial database containing coordinates for stars in the sky?

My goal is to map the Skydome ( stars in the sky projected in earth surface ) using GIS. Has anyone done this before? I can't find any project close to this. What I just need to know is if there is ...
1
vote
1answer
86 views

Scaling CartoDB to multiple machines

I'm interested to scale CartoDB installation to multiple machines to distribute computational resources. We start using torque with some big tables (more than 5 to 10M points) and the processing for ...
4
votes
1answer
936 views

Copy a spatial table from one PostGIS database to another PostGIS database

I have two PostGIS databases on two different servers. The first server is PostGIS 2.0 and the second server is PostGIS 1.5. On the PostGIS 2.0 I have a table "lakes" with MULTIPOLYGON geometry ...
3
votes
1answer
159 views

Computing radius of gyration in PostGIS

The radius of gyration is a measure of the standard deviation of distances between points (and their center of mass), i.e., how frequently and how far points are moving. A formal definition is: I ...
2
votes
0answers
134 views

How to best intersect vector data with raster data?

I have Open Street Map [OSM] data imported so that I can access the geometry of buildings. I have also loaded SRTM digital height data from NASA from a GeoTIFF raster. I have projected the raster into ...
0
votes
2answers
161 views

PostGIS - Select points from a table that exist in a custom polygon

We have a property search site where the user draws a polygon on a map and then the app displays all properties that fall within the polygon. We have properties stored within a Postgres table that ...
6
votes
2answers
353 views

How to check if points are within a circular sector using PostGIS?

I want to get the stars within the black region as shown above. To find this I have the centre of circle (lat, long), radius and the angle of region (45 degree). I am new to postgres. I worked on ...
0
votes
1answer
243 views

Why does reading shapefile from PostgreSQL database give Error reading OID from table …?

I'm using arcgis 10.1 and i have a connection to a PostgreSQL 9.3 database. When i try to load a shapefile using the add query layer I get an error when opening the attribute table. The error says ...
2
votes
3answers
263 views

Why are some points in my PostGIS layer not displayed?

I have PostGIS table with some points and various attributes. Yesterday I added some more points to the table and now weird things are happening when I try and display layers built from these points. ...
3
votes
2answers
165 views

How to handle PostgreSql 1:m relationship data by using “Data-Driven Input Mask” QGIS plugin?

I have 1:m relationship tables in my PostgreSql. I like to show the main table attributes as well as the relational table attributes (like grid rows) in QGIS attribute-edit-form. What are the entries ...