1
vote
2answers
40 views

What is best way to reorganize osm into PostGIS database entity?

I'm just wondering how to reorganize the OSM given entity to more flexible and schematic purpose. The OSM gave 4 entities the planet_osm_line, planet_osm_point, planet_osm_polygon and ...
0
votes
3answers
79 views

How to Build a graph from a map

I spent days looking in all questions here and trying tutorials. I need to build a graph for a region (It will be my input in simulation) I downloaded Postgresql and Postgis and osm2pgsql. Now i can ...
0
votes
3answers
63 views

ST_transform postgis

SQL within that zone is a point SELECT "public".zona.zts FROM "public".zona WHERE ST_Within ( ST_Transform ( ST_GeomFromText ( 'POINT(-30.033514 ...
0
votes
2answers
61 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 ...
3
votes
1answer
191 views

Problem PostGIS Spatial Query ST_Contains ST_Disjoint ST_Intersects

I'm working on a project with two different tables inside a database. One contains points in a column geometry(Point,4326) type and the second one has a column geometry(MultiPolygon,4326). Now I would ...
0
votes
1answer
90 views

Import Shapefile on postgis doesn't show in QGIS

I'm currently working on a project about a database and some shapefiles. The database is built on PostGis with tables including some dots as geometry type columns. Once imported them on QGIS, I can ...
1
vote
2answers
101 views

Most optimal way to create a (spatial) database for big amounts of data?

I am using QGIS, and on my way to set up a huge spatial database (geographical), where most of the data is points without geometry), along with other types of data (like lines in DXF and areas in ...
1
vote
1answer
32 views

Strategies for managing (and ultimately merging) duplicate business locations in a spatial database

I am working on a project right now that involves using multiple (very large) "location directories" to identify with the highest possible inclusiveness, a diverse set of business locations. These ...
3
votes
2answers
66 views

Is transformation of spatial data lossy?

I have a shapefile that contains data of a country from the following Geographic Coordinate System ( GCS_North_American_1927 aka NAD27 ) contents from the shape file .prj: ...
4
votes
1answer
103 views

Homogeneous vs Heterogeneous schema in Postgis

Introduction I'm working on creating a spatial database in Postgis, to be viewed and edited trough QGIS to help managing some farmland areas. One of my goals is the have a centralized place where ...
1
vote
0answers
48 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 ...
4
votes
1answer
395 views

How to create linestrings with a definite angle and length, that are fixed to a point

I want to create linestrings with a definite angle (e.g. 160°) and length (e.g. 2m) that are fixed to a number of points of another linestring. So, I want to use the ST_DumpPoints function to find the ...
1
vote
0answers
34 views

How to load or query data directly to R from a PostGIS database using RPostgreSQL and rgdal [duplicate]

Is it possible to load/query a shapefile to R, which is stored in a postgres/postgis database? I've built up a connection to my postgres database via DBI, RPostgreSQL and I want to make some ...
3
votes
1answer
78 views

Should states/provinces be stored as geographic or geometric data types?

While reading the GeoDjango documentation, they advise using geometric rather than the geographic data type when storing values that are on a continental scale. The Canadian province of Ontario, for ...
9
votes
6answers
1k views

Is there a way to connect to PostgreSQL in ArcCatalog without SDE? [duplicate]

Is there a way to connect to PostgreSQL in ArcCatalog without SDE? I came across this post from 2011 that suggested using zigGIS but I can’t find a working link to the program. A little background: ...
0
votes
1answer
81 views

Schema for offline map editing and pass to production environment

I'm working with QuantumGIs and PostgreSQL/Postgis. So when I edit the layers, the changes are reflected on the DB. The thing is I want to do some "offline" editing before committing the changes to ...
1
vote
0answers
37 views

Determining the SRID of a dataset in PostGIS [duplicate]

Sometimes the dataset provides some information about its projection. For example, it can mention Horizontal_Datum_Name: North American Datum of 1983, Ellipsoid_Name: GRS1980, ...
2
votes
0answers
112 views

How to Create database using OGC compliant geometries and Custom type Geometries?

I am interested in storing geometry attributes in a PostGis database, so that it would be OGC compliant, along with OGC compliant geometry types like point,line, linestring, etc. I also wanted to ...
1
vote
3answers
162 views

Copying schema of Postgis or Spatialite DB to blank one

I want to copy a Postgis or Spatialite DB sctructure (features, tables) to a blank DB. In ArcGIS i can easily handle it by using XML Workspace Document. Fisrtly extact it from a Geodatabase and than ...
3
votes
1answer
558 views

Setting geometry types importing to PostGIS with OGR

I'm using ogr2ogr to import data into a PostGIS database. Each dataset I need to import has (theoretically) the same exact data structure, but it appears that they are not the same geometry types. ...
2
votes
1answer
80 views

point of intersection issues

I have a table containing a set of points of intersections. Most of the roads intersects whith just one road BUT i have some roads which intersects with two, therefore three different point of ...
4
votes
2answers
322 views

PostGIS stored procedures

I am wondering if there are open source applications that make extensive uses of the special functions (the ST_* stored procedures) provided by PostGIS? I found many apps that support storing map data ...
3
votes
1answer
504 views

Routing with multiple points

I am using postgreSQL, postGIS and pgrouting. Now I am really confused on how am I going to find the shortest path between multiple points. I know how to find it between two points through dijkstra ...
1
vote
2answers
1k views

mulitlinestring to linestring

I am using postgres with postgis and I have a set of points which I would like to interpolate with a set of lines. Now my problem is that the set of lines are of type multilinestring. Is there a ...
2
votes
1answer
123 views

St_buffer width issues

I am using postgres with postgis for spatial data and ArcGIS for visualisation. I am really confused regarding what units the st buffer function uses because when I insert just the value 1 as ...
2
votes
1answer
104 views

postgis values within XYZ viewport in openlayers

I got this XYZ server where I get my maptiles. Now, when the user is at zoom level 1 ( closest). I want it to execute a command that gets the current viewport from the map and Queries my PostGIS ...
13
votes
5answers
401 views

What in-depth spatial database systems tutorials exist?

Is there a good tutorial that explains in depth the internals of a GIS and a spatial database system such as PostGIS with examples and without any background assumption? I'm specifically looking for ...
9
votes
2answers
1k views

Postgres/Postgis spatial index - no speed up

I have a spatial table in a postgres/postgis database. Every row in it represents a Polygon. It is of following form: +----+--------+ |gid | way | +----+--------+ |241 | 01030..| The geometric ...
1
vote
0answers
28 views

Creation of 3d terrain from real data [duplicate]

Possible Duplicate: 3d terrain from data in postgres I am pretty new to spatial database and 3D data. I have a project where i have to create a 3d terrain from data being taken by me by a ...
2
votes
1answer
161 views

Finding the Geometry within which a Point falls

I have the following query, which takes on average about 4 seconds. How might one improve the query such that the same response comes back faster? SELECT * FROM geometries g ORDER BY ...
4
votes
1answer
910 views

Error creating a spatial database. ERROR : could not load library “/usr/pgsql-9.1/lib/rtpostgis-2.0.so”

I am running PostgreSQL 9.1 with Postgis 2.0 on Fedora 15. When trying to install the raster support, psql -d mydb -f rtpostgis.sql -v ON_ERROR_STOP=1 I get the following error ...
7
votes
2answers
4k views

Spatially enabled Postgres database

I am trying to create a spatially enabled PostGIS database. I am following the PostGIS documentation, http://postgis.net/docs/manual-1.5/ch02.html#id2648455. In the short version, i executed, ...
2
votes
1answer
711 views

MySQL GeoSpatial function for ST_Distance_Spheroid? Metric used in return Type of GLength?

Is there a ST_Distance_Sphere, ST_Distance_Spheroid equivalent function in MySQL's GeoSpatial Support? If not, any way to emulate this? What is the metric used in return type of ...
5
votes
1answer
3k views

How to create a table from existing tables (applying new schemas) in postgis DB?

I have a table that is geospatially enabled; that contain world borders. I want to break it down to different schemas (global, europe etc..) . My thought is to use use something that looks like this: ...
13
votes
2answers
21k views

How to insert a point into postgis?

I have created one table in my Postgis. But I can not insert point. I do not know what's wrong with my query? CREATE TABLE app ( p_id INTEGER PRIMARY KEY ); SELECT ...
2
votes
2answers
902 views

DatabaseError: Coordinate values are out of range [-180 -90, 180 90] for GEOGRAHY type

I am using Django 1.3, PostGIS 2.0 , Postgresql 9.0 and GeoDjango. I had a database with a table for places. This table had latitude and longitude for places in the US. I enabled this database with ...
1
vote
0answers
225 views

Manifold 'Link drawing to query' - can I do this in QGIS?

Manifold GIS allows the creation of dynamic drawings linked to queries. Unfortunately I do not have access to Manifold as my employer refuses to pay for it, so am currently investigating ...
1
vote
1answer
241 views

How to get route plan with certain distance with pgRouting?

I am working for a project. I have a road network which has been imported in PostgreSQL/PostGIS database. I can query shortest path between two points. I want to get route plan with certain distance. ...
1
vote
2answers
152 views

How to fix “Error, query must return columns 'id', 'source', 'target' and 'cost'”?

I have one spatial table with gid, FNODE_, TNODE_ and LENGTH column in my Postgresql/PostGIS database. I am using pgRouting. Problem is, when i try with shortest path query it shows following error. ...
10
votes
1answer
896 views

Can you query overlapping user-defined polygons at a given point in Google Maps?

I need to find out the limitation of working with the Google Maps API, and the possible solutions for doing semi-complex spatial comparisons. What I'm looking to achieve is a system of comparison ...
5
votes
2answers
480 views

Reduce Tracking Data Set

I'm building an application that uses data from GPS units on board vehicles and displays it on a map. A lat/long is recorded every .5 seconds and a session can be many hours... this can add up to be a ...
19
votes
3answers
2k views

When should you NOT use a spatial index?

I am asking this because I was mainly working with Oracle but for the past year I've been doubling with PostGIS and SQLServer 2008. Most spatial functions in Oracle won't work without a spatial index ...
12
votes
3answers
1k views

Future of spatial databases

It may be a bit off-topic. I am eager to know the industry specific importance of Spatial Databases. Is Spatial Database a very important part of any GIS system? Or will we use other technologies to ...
12
votes
2answers
1k views

Mixing geometry types in one PostGIS table

I've faced with the following problem. I have to migrate from Oracle database to PostgreSQL+PostGIS. Currently all geometries of all types are stored in one table and each record contains "lid" field ...
18
votes
7answers
1k views

Spatial databases learning resources for newbies

Would be taking up a course on spatial databases next semester. Would anybody know a newbie friendly introductory resource? A vendor neutral one would be preferable. Thanks.
9
votes
3answers
2k views

Beginner PostGIS question: getting geometry from multiple tables

I am very new to PostGIS, PostgreSQL, and SQL in general. I have 44 tables in my PostGIS database, and each one represents a different layer of vector data. Each was loaded from a separate shapefile, ...
12
votes
4answers
427 views

What is a suitable Global/Universal Unique Identifier for a PostGIS database?

I have read that using OIDs as a primary key in a postgreSQL/PostGIS db is poor practice because there are instances where these can be reset. Sounds logical, but then what is a suitable alternative? ...
12
votes
3answers
912 views

Centralizing shapefile data into database

I've got hundreds of shapefiles from various different GIS projects that I want to start consolidating into a single database platform, currently attempting this with Postgres / PostGIS. Hardly any ...
3
votes
3answers
733 views

Spatial Database Design (PostGIS) - Point data that doesn't always have spatial data

I am creating a spatial database using PostGIS. I am storing the attributes and location of some species records that can be represented as points. The records are recorded from either: a) static ...
20
votes
4answers
2k views

Would PostGIS offer an advantage over MySQL for a produce farm application?

I have a web app that stores the locations of farms in West Michigan. You can search for a product (e.g. "broccoli") and it will show you all the farms that grow that product. Right now I'm using ...