PostgreSQL is an open source object-relational database system.

learn more… | top users | synonyms (1)

1
vote
0answers
97 views

Do ArcGIS clients that direct-connect to postgresql/postgis databases override configuration settings?

I went in to modify some settings on a Postgresql database via the PGAdmin config editor and some of the settings don't have their default values and they are higher because they've been overridden ...
0
votes
2answers
89 views

Problem with a PostGIS trigger

I'm trying to update a lat and lon columns each time I insert a point with a trigger, but I don't know why I get an error. This is the syntax I'm writing: CREATE OR REPLACE FUNCTION update_tg2() ...
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
0answers
26 views

Geoserver - How to make a psql-backed timestamp that uses timezones

I'm working on an application that extends geoserver and am frustrated as I'm trying to define a SimpleFeature that has timestamps that include timezones. I've tried declaring my timestamp field ...
4
votes
1answer
100 views

PostGIS: Strategy for fastest select by BBox with an ORDER BY polygon area clause. Cluster?

Update 2 (below) suggests 14% of the table geometries are stored out-of-line with the rest of the table records. This may be a useful clue. The Problem: We've got a table with appx 170,000 WGS84 ...
3
votes
1answer
128 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 ...
-3
votes
2answers
62 views

Fractional Area Calculation

I have a file (in both raster and vector) of different districts in a country. I have also made a grid of 1 deg * 1 deg (both vector and raster) of the country. I want to calculate the area of each ...
1
vote
0answers
61 views

PostGIS is not seeing any GDAL drivers

I've tried setting POSTGIS_GDAL_ENABLED_DRIVERS=ENABLE_ALL as an environment variable. As well as running SET postgis.gdal_enabled_drivers = 'ENABLE_ALL'; from psql. (With a pg_ctl restart after each) ...
0
votes
1answer
83 views

find all circles intersecting another in a table [duplicate]

I am using postGreSQL (9.3) and postGIS (2.1). I have a table containing names and circles (point + radius). Given a name and a circle (point + radius), I would like to find all the database lines ...
-3
votes
1answer
66 views

How to use st_touches to get all nearby states

I have a table with all US states geometrical data: USstate ------- state | The_geom (here filling in random value) AL | 00012312 NM | 000234234 NJ | 0000234534 NY | 00005465 ...
4
votes
2answers
268 views

PostGIS: ST_Equals false when ST_Intersection=100% of geometry?

I have 2 datasets consisting of cadastral parcel data - roughly 125,000 rows each. The geometry column is WKB polygons representing parcel boundaries; all data are geometrically valid (the polygons ...
2
votes
1answer
70 views

How can you tell which port number an existing Database Connection is configured for?

I have a database connection to a postgresql database on a non-default port, 5433. I specify TESTDB,5433 as the instance and I can connect with no errors. If I open that connection properties ...
3
votes
0answers
69 views

Is it possible to replicate an SDE geodatabase including the archive tables?

I have a database in one location which I would like to replicate to another using one-way replication. In testing we haven't been able to replicate the archive tables, which is unfortunate because we ...
0
votes
0answers
90 views

Create a route by using points (pgRouting)

I'm currently working on a routing model for 17th and 18th century voyages. These routes are based on data from old shipping logbooks. I made a separate layer in QGIS which contains point. I exported ...
5
votes
1answer
283 views

Maritime route prediction avoiding land masses

I am working on a project where the following functions have to be implemented: Predicting the locations of the ships (in maritime environment) at a future time. (Can be done with Kalman filter, IMM ...
0
votes
1answer
359 views

How to store Google Maps DrawingManager Rectangle overlay in PostgreSQL Postgis GEOMETRY(GEOMETRY, 4326)

What is the correct way to store a Google Maps DrawingManager rectangle overlay? The API basically provides me with NE & SW lat/long coordinates. Should I use BOX()? Is it possible to create a ...
1
vote
1answer
95 views

How to define Z dimension on table with PostGIS for import in TileMill?

I'm trying to reproduce the idea behind this blogpost from Mapbox, but with other data, for example the ne_10m_populated_places_simple dataset from Natural Earth. By adding a z-dimension to the data ...
1
vote
1answer
69 views

st_length column in Postgres db and ArcGIS under WGS84

I have a polyline feature class in ArcGIS running on top of postgres in WGS84 datum. I am wondering what is the unit of length used to drive st_length column under this datum and what is the method of ...
0
votes
0answers
103 views

Installing mysql_fdw on Windows

I want to create a join between a spatial database (PostGIS) and a non spatial database from MySQL. Both databases have a unique ID who can be joined. I found a way to do this with PostgreSQL and a ...
0
votes
0answers
80 views

How do you unregister a table from a esri geodatabase?

How do you reverse the "Register with Geodatabase" operation? I reckon it isn't uncommon to accidentally register (since it is the first option on Manage menu in ArcCatalog 10.2). Is there a tool ...
1
vote
0answers
105 views

Plotting points on a map, the json objects retrieved from a database; using WebGL shader code

I am using an OSM dataset using which I am plotting those points on a map (google maps API). I am plotting these points using webgl shader code (see:  http://psousa.net/demos/webgl/) The above link ...
1
vote
1answer
56 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 ...
0
votes
1answer
38 views

Problem with ST_Intersection in postgis

I have got a problem with ST_Intersection as bellow query. I do not know why I can not get element z of this intersection? ----query: SELECT ST_AsText(ST_Intersection('LINESTRING Z (0 0 0, 2 2 2)', ...
1
vote
1answer
73 views

Extracting specific geometry point from MultiPoint geometry using PostGIS?

I am working with multipoint geometries in postgis and would like to extract the geometry point associated with the greatest y value of the multipoint geometry. How may I accomplish such a task? For ...
0
votes
0answers
111 views

How to import osm.pbf file into database with Python Imposm

I want to import a .osm.pbf file with the Python library Imposm. Currently my work flow is the following: import requests import os city_name = 'santiago_chile.osm.pbf' url = ...
0
votes
0answers
57 views

Make PostGIS points from Ajax data in a php file

I have an AJAX a string which has lat-long parameters in a request. I try to make point in an SQL query but I get this error 37.15452626 ERROR; parse error- invalid geometry HINT: ...
1
vote
0answers
76 views

PostGIS: Ordering by the sum of two distances

I have an SQL statement that selects possible bus routes between two points, ordered by the walking distance required from the start point to the departure bus stop (distance1) and the arrival bus ...
1
vote
0answers
69 views

PostGis without shp2pgsql

I recently reinstalled postgis on my pc, following these instructions link. The installation is successful, and for several days work using PostgreSQL and PostGIS without problems. Now, I need to ...
1
vote
0answers
34 views

ST_Split and looping problems PostGIS

I am a total PostGIS noob, and am having trouble understanding the finer points of SQL syntax. I am trying to take a large set of line data and clip it with a polygon. I then want to create a new ...
3
votes
1answer
7k views

Transforming from SRID 900913 to 4326 with PostGis

I have two Postgres tables with different SRIDs: 4326 and 900913. I want to convert the latter to 4326. I first changed the SRID using: Select UpdateGeometrySRID('table', 'geomcolumn', 4326). I ...
1
vote
2answers
104 views

How to populate a table with geom line? [closed]

I have the coordinates of a lot of points in a table. In pgadmin I want to make a line that passes on these points. I already have my Coordinate point im my table. I want to make line with those ...
1
vote
0answers
31 views

pgRouting. pgr_ksp() returns -1 as id3

The documentation (http://docs.pgrouting.org/dev/src/ksp/doc/index.html) says that the result should be 0 for the last row. Is the same 0 than -1? I'm new on this. Thaks for the help.
0
votes
0answers
22 views

Update Statement in PostGIS ERROR

I am trying to update a column in PostGIS using information from a column in another table where they spatially intersect. I looked up how to do this on the PostgreSQL tutorial and I think that I ...
0
votes
0answers
35 views

Displaying measurements on a grid of the Earth

I'm developing an application where I need to draw the averaged results of some measurements on a map. Right now, I'm using Leaflet to draw the map with MapQuest/OpenStreetMap tiles, and have the ...
7
votes
4answers
5k views

Connecting to ArcGIS Desktop PostgreSQL database (running locally)

I know this is a total noob question but then again, when it comes to PostgreSQL I am a total noob... I have installed the OpenGeo suite on my computer, running Windows 7, 64-bit. I have ...
1
vote
1answer
141 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 ...
3
votes
1answer
161 views

PostGIS - ST_Within or ST_Disjoint performance issues

I have a table of about 150,000 points in PostGIS with a spatial index and a SRID of 27700 (OS). I want to select the points that fall outside England and Wales. I have a multipolygon table with ...
-1
votes
2answers
203 views

How to populate my table with data in excel format?

I have 160000 rows of data in Excel and I want to put them in my table in PostgreSQL. How can I import X,Y coordinates from my excel file to my table in postgresql?
0
votes
2answers
242 views

Postgresql trigger on a table that update a field

Depending on values on 2 fields A and B, I would like a field C to be updated or filled with a specific value. For example : create or replace function periode() returns trigger as $BODY$ begin IF A ...
0
votes
1answer
60 views

Use C# to display PostGIS data in ArcGIS Developer kit with arcgis-ogr plugin

I am trying to display data in ArcGIS Runtime Engine Developer kit 10.2.2 using OGRPlugin/OGRPlugin/ develop by Ragi Yaser Burhum on https://github.com/RBURHUM/arcgis-ogr . I am using this format but ...
14
votes
2answers
3k views

Which function for creating a POINT in PostGIS?

When defining a Point in PostGIS, when do you decide to use which of the following? ST_SetSRID(ST_MakePoint(lon,lat),4326) ST_SetSRID(ST_Point(long,lat),4326) ST_SetSRID(ST_GeomFromText('POINT(lon ...
0
votes
0answers
65 views

How to get elevation of a coordinate given a dtm file out of a PostGIS?

What would be the best way to get elevation of a coordinate out of a PostGIS database (SQL/plpgsql) given a GeoTIFF dtm file? Importing as PostGIS Raster (which seems more costly) and calling ...
1
vote
0answers
73 views

Trying to install PyGreSQL, receiving DLL load failed error

I am trying to install the PyGreSQL package into Python 2.7. I am running 32-bit Python on a 64-bit Windows 7 machine. The installer I am using is the file PyGreSQL-4.1.1.win32-py2.7.exe from here. ...
0
votes
0answers
22 views

php script with lat and long for postgresql

I would like to create a postgresql geodatabase able to display, with OL3, data entered through a php script. In the php script i indicated the two fields latitude and longitude data as numeric ...
0
votes
0answers
44 views

Use another schema than public in geoserver monitoring plugin

We want to use the Geoserver Monitoring Plugin, based on a PostgreSQL 9.3 database. It works fine except that the plugin create the tables request and request_resources in the public schema, while we ...
0
votes
1answer
101 views

how to fix this ERROR: Start vertex was not found

I am attempting to make an SQL selection but receive an error. My statement: SELECT * FROM network JOIN (SELECT * FROM shortest_path(' SELECT gid AS id, start_id::int4 AS source, end_id::int4 ...
1
vote
1answer
66 views

slow Openlayers with 270000 points

I have 270 000 points on a map. If you zoom out, the site hangs for a very long time and sometime the page just crash. I use Cartaro with Drupal. https://www.drupal.org/project/cartaro Cartaro is a ...
3
votes
3answers
4k views

Install the Pgadmin3 shapefile importer plugin on a Mac(10.8)?

I'm new to GIS related things and I'm setting up a Postgre/Postgis database for geospatial queries. I'd like to import various shapefiles into the database and I found that Pgadmin3 has a shapefile ...
0
votes
0answers
29 views

Query processing time for network table creation using pgRouting 1.05

I am trying to follow these steps for creation of a network table using pgRouting 1.05. In my case I have two road geometry tables, one is bangalore_road and the other is all_india_roads. Obviously ...
0
votes
1answer
29 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 ...