Tagged Questions

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

learn more… | top users | synonyms

2
votes
0answers
142 views

qgis-2.2.0 database tab missing

I have recently installed QGIS-2.2.0 but the Database tab in the top-menu bar is missing. It looks the main reason is missing libgdal1h library. But when I am installing it, it's removing ...
0
votes
1answer
54 views

Missing hstore column in TileMill!

I made a PostgreSQL with PosGIS Extension DB with the pgsnapshot_schema and loaded an .osm.pbf-file with OSMOSIS into it. Now i connected it to TileMill, but if i look up into the table i just see ...
-3
votes
1answer
82 views

Is it possible to access geoserver wfs layer from localhost:8080 in to web application? [closed]

I want to add a WFS layer. I am trying to get WFS layer from localhost:8080 geoserver. but I am getting eoserver DateLineWrap in Openlayers.js file...
0
votes
1answer
34 views

I need to test a condition within the sql in postgis.

I need to test a condition within the sql in postgis. My sql: SELECT (zoneamento3_32722.zt3), logradouros32722."NMIDEABR", logradouros32722."OBJECTID", ...
0
votes
2answers
52 views

PostgreSQL/PostGIS - group by series of values

I need to sum up linear objects' length and to group them by intervals of several years. I have one table storing my objects like this : - gid serial NOT NULL, - year INTEGER, - the_geom ...
2
votes
1answer
109 views

Centroid of Points using postgis

In my postgres database i have a set of points(lat, long) and i created the_geom index for that. Now i have to find the centroid of these points. I Google a lot and i find that for closed ...
0
votes
0answers
27 views

PHP Query Tables of Active Layers

I currently have an "Identify Features" function on my site that works by passing a the Lon and Lat of the click, along with a list of active layers to a PHP script that will then query my PostGIS ...
0
votes
2answers
54 views

How to join data in postgis tables to form layer with subset of attributes

In QGIS I am trying to join data from two postgis tables. I can not figure out how to do this at sql because add layer tools seem to allow one to select just one table to filter on. Instead I ...
1
vote
1answer
133 views

QGIS/PostGIS: Select Counties within Region via Spatial Query

I'm using GQIS 2.2 and PostGIS on Postgresql 9.3. I have 5 regions in the contiguous United States. Each region has states, and each state has counties. I would like to think that the data I'm given ...
0
votes
1answer
76 views

osm2po is missing edges while importing to pgrouting

I am using osm2po for importing pbf file to postgresql but when i find route using built-in algorithms i found that some of the edges are missing so route does not match with road. Did anybody know ...
0
votes
1answer
68 views

Searching closest region from Google Maps coordinates

Here is my problem. I'm mapping a region in google maps after that I'm saving the coordinates in PostGIS databse as geographic Polygon type. ST_GeographyFromText('SRID=4326;POLYGON((..))') The goal ...
0
votes
1answer
117 views

Drawing curved lines in CartoDB?

I am experimenting drawing curved line from Origin to Destination in Cartodb. I was able to do so once, however, failed the second and third time. Could anyone offer me some insights into the ...
0
votes
0answers
42 views

Installing PostGis / GeoServer in Mac OSX

On a Mac Server I am working to setup the ports. My understanding is that there is a system instance of PostgreSQL running and then a geoserver instance. Version is 10.7.5. I need help approaching ...
1
vote
0answers
114 views

Can't see Postgis layers added to QGIS

I'm trying to transition from an old Postgres/Postgis database to a new one. I'm working in a fresh install of Win 7 64 bit. I installed Postgresql 9.3 32 bit, then installed PostGIS 2.1.3. I created ...
0
votes
1answer
62 views

Calculating a vector raster intersection in postgis

I am using CartoDB and trying to calculate the total population (in raster format in popcount) within a specified distance to a line (vector data in mytable). The population data is at about 5km ...
1
vote
0answers
85 views

Collapse dual carriageway lines in PostGIS

I have OpenStreetMap data, which represents larger roads (e.g. dual carriageways, aka divided highways) as parallel lines. The question is answered for ArcGIS or Skeletron here, for example using ...
0
votes
1answer
155 views

How do I avoid this osm2pgsql duplicate key error in Windows?

I am attempting to load an OSM .bz2 file into a PostGIS database using osm2pgsql but am stuck at a duplicate key value in the nodes which violates a unique constraint - any suggestions? output is ...
1
vote
1answer
148 views

Development guide for beginner? [duplicate]

Im new to GIS and mapping, and I need to learn how to create web map application for my project. I'm really confused on what to use. I have read PostGIS, OpenStreetMap, and Openlayer. I'm wondering ...
2
votes
1answer
281 views

POSTGIS - calculating percent area of intersection in where clause

I have a table of polygons (census block groups) in postgres. I want to tag each block group with the town (another polygon table) it mainly resides within. Is this possible? I'm thinking I'd need to ...
0
votes
2answers
177 views

Import DEM into PostGIS for QGIS

I'm a complete GIS newbie so sorry if I'm using the wrong terminology in searching for a solution to this... I'm trying to import a DEM into PostGIS and display it in QGIS. The data is from the EU-DEM ...
0
votes
1answer
468 views

How to use Google Maps projection with GeoDjango/PostGIS

I am building a web service with GeoDjango which involves user submitted events including a location. I created a model field for my location using django.contrib.gis.db: location = ...
2
votes
1answer
63 views

When I publish a layer(shapefile or postgis) with TileMill, 200 meters moves

I hope someone can help me. Not if you know the TileMill application I'm working with her to publish layers look more beautiful. Well, first I have posted directly loading the shp file., But when ...
1
vote
2answers
68 views

how to do simple self join and touches function in postgis?

I am having trouble with this query and neighbor calculation in PostGis. I want to find out which are the neighbors of Sweden in the table COUNTRIES which has column 'the_geom' for geometry and ...
0
votes
0answers
39 views

Serial Int Primary Key not recognized by QGIS 2.2.0

I have a table "lines" stored as MULTILINESTRING features in PostGIS 1.5 ---------- -- Begin Table Definition: CREATE TABLE lines( gid serial NOT NULL, geom geometry, CONSTRAINT roadgeo_can_pk ...
1
vote
1answer
42 views

Break line into 100m segments

I have a line geometry in PostGIS and I am wondering how I would break the line into 100m segments. Is there a function for this?
1
vote
2answers
117 views

invalid KML representation on ST_GeomFromKML

I exported a table with a geography(MultiPolygon,4326) column using ogr2ogr to a KML file. When trying to re-import any of the shapes using the ST_GeomFromKML function I get the following error: ...
2
votes
0answers
156 views

TileMill Exports Failing

I'm having trouble exporting my map in TileMill (v0.10.1). I'm using OSM Bright with a PostGIS database connection to import OpenStreetMap data. When exporting an SVG or PDF through the user interface ...
1
vote
3answers
243 views

geography, geometry, distance, and wkt - PostGIS

I'm trying to understand the data conversions that happen in PostGIS when calculating distances in SRID 4326. Why is it that when I run on my marin_jobs points table: select cast (the_geom as ...
2
votes
0answers
67 views

QGIS is not working with Postgres Plus Advanced Server

We have a problem to integrate GIS software with our GIS database which is populated on Postgres Plus Advanced Server 9.2 from EnterpriseDB. We are using QGIS to maintain and analyze our GIS ...
0
votes
1answer
135 views

pgShapeLoader: how to load a shapefile in a different schema than 'public'

I'm trying to load a shapefile in POSTGIS using pgShapeLoader. It works but I can load table only in the "public" schema and i don't know how to configure, the tool to upload my shapefile in another ...
4
votes
2answers
755 views

Postgis 2.1 error after update

After a usual update progress - "apt-get upgrade" - I can not connect with qGIS to my PostGIS DB anymore. Error in the qGIS logfile: Your database has no working PostGIS support. Erroneous query: ...
1
vote
1answer
153 views

Geoserver OSM data Imported via osm2pgsql - most efficient tables to use to style roads

The Osm2pgsql importer for OSM data to Postgres results in two tables for ways, one called planet_osm_roads and a second one called planet_osm_lines The Osm2pgsql documentation states that the ...
0
votes
0answers
62 views

Displaying 3D city model from PostGIS 3D backend

I know that openlayers doesnt support 3D yet. I heard about Kartograph has 3D features but Does Kartograph support reading data from backend database especially PostGIS? I would like to create a 3D ...
1
vote
1answer
60 views

Possible to store 3D features such as dome into geospatial database?

Is it possible to store 3D features such as dome into geospatial database such as PostGIS? I know that it can store x,y,z data, can such complex features be stored into database?
1
vote
3answers
205 views

Dismiss invalid Polygons in PostGIS

I Have a massive Dataset from OpenStreetMap and imported it into a Postgres-Database using ogr2ogr. I got several warnings during this process because of multipolygons with too little vertices. Now I ...
1
vote
0answers
65 views

Add polygons to PostGres to be queried by Nominatim

I'm trying to build out a geocoder that also returns the correct legislative district information from this data: http://www.census.gov/geo/maps-data/data/tiger.html I've got OSM data imported into a ...
0
votes
1answer
92 views

How can I find the segment of a line that lies within a polygon using Postgis?

Given a "road", represented by a line, that crosses a "state", represented by a polygon: What is the SQL query I can use to find the segment of the road that is within the state? A concrete example. ...
0
votes
0answers
53 views

PostGIS Function both work fine

I create two function both work fine same solve, but one of them, take to much time (which one use "temporaly"). Is very important because I will run in several times the funcion. Please any one can ...
1
vote
2answers
67 views

How to get a set of all buildings of an OpenStreetMap section in form of single points / Multiple polygons as one point

The objective is to get a set of all buildings of an Open Street Map section in form of single points in a shapfile. I downloaded the section from osm. Imported the section into QGIS (and later ...
1
vote
0answers
86 views

Open PostGIS layer with QGIS 2.2

I just upgraded QGIS from 1.8 to 2.2 and I am getting some troubles to open a PostGIS Layer. The connection with the server works fine, I can see all my tables, select the one I want to open and even ...
1
vote
1answer
49 views

Why is “Add feature” of the GPS Information tool inactive for some of my PostGIS layers?

Sorry If I rise it again on this forum but I couldn't find any info on limitations/requirements of "GPS Information" tool for QGIS (2.2.0) against data layers. For some layers I'm able to collect ...
2
votes
1answer
114 views

Reverse Geocode with PostGIS use Open Street Map Database

I want to reverse geocode with postGIS use OSM database, I use FUNCTION: <!-- language: lang-sql --> CREATE OR REPLACE FUNCTION khoangcach(lat double precision, lon double precision) RETURNS ...
0
votes
0answers
74 views

Using postgis functions in ArcGIS Server 10.2 for Layer Definition Query

I asked the previous question Using PostGIS functions in ArcGIS Desktop for Layer Definition Query? And got an excellent answer. However this covered ArcGIS Desktop. In 10.0 it seemed that if I got ...
1
vote
0answers
53 views

PostGIS raster connection is not closed by MapServer

I'm using PostGIS raster in MapServer like this: TYPE RASTER DATA "PG:port=6432 dbname='mydb' user='postgres' password='1234' schema='public' table='truemarble' mode='2'" PROCESSING ...
0
votes
2answers
75 views

How to select the cross streets in postgis spatial table?

I've used ST_Intersects and ST_Crosses but between two different tables. I have a table of streets and intersections want to know them. For example select all streets that cross the Street A. Can ...
1
vote
1answer
238 views

Setting up PostGIS: Postgres can't see the PostGIS extensions?

I've just installed Postgres 9.3.4 and PostGIS 2.1 on OSX Mavericks using the very latest versions of the KyngChaos libraries. This is a new machine, and I deliberately haven't installed Postgres ...
0
votes
2answers
58 views

Identify circuits/loops in GPS track data

This question will be naive and uneducated, but I gotta start my research somewhere, so I'll ask for references and pointers... Let's say you have a GPS time series with a set of lat/long coordinates ...
1
vote
1answer
50 views

how to add data from a layer to postgis table with different field names

I am importing waypoints from GPS (in gpx format) using Layer>Add Vector layer and then I want to clean up the data and add some more attributes and finally add them to a master table in PostGIS. The ...
0
votes
1answer
63 views

PostGIS Spatial Index not used after copying table

I am copying a PostGIS database from my computer to our webserver. I always had problems to copy the entire database using pg_dump and pg_restore so I am creating a new database on the server and copy ...
3
votes
1answer
66 views

Rounding bug using ST_GeomFromGeojson()

Let's say I have the following geographical point represented in GeoJSON: {"type":"Point","coordinates":[-109.0,35.292506]} When I run the following conversion, things work as expected: SELECT ...