pgRouting extends the PostGIS / PostgreSQL geospatial database to provide geospatial routing functionality.

learn more… | top users | synonyms

0
votes
1answer
37 views

problem transforming pgr route to a line - unexpected extra lines from St_MakeLine

I have created a line geometry from a pgr_dijkstra querry and I am getting an unexpected looking line in qgis. The following image illustrates the problem: The magenta line is the line created ...
1
vote
2answers
67 views

adding geometries to a source, target table for multiple rows in pgrouting

I am having an issue trying to perform the pgr_dijkstra algorithm and getting back a line in my table for multiple rows. I have a table that has a columns of source, target node id's but I cannot ...
0
votes
2answers
93 views

creating isochrones in postgis/osm2po/pgrouting and then saving the isochrones as polygons

So I am creating some isochrones in pgrouting based upon a table from osm2po. Now I have a query that will get all of the edges that are c driving distance away from a point. My question is, how can I ...
0
votes
1answer
22 views

PGrouting encapsulated queries error [quotes problem]

I'm facing a quote problem on a pgrouting query. What I'm thinking is wrong is that my query only works if I use one, then four, then eight quotes on encapsulated queries. Is there a way to simplify ...
3
votes
2answers
118 views

How to connect points (bus stops), which don't lie on the lines (LINESTRING), to a network?

I need to connect bus stops (points) to a network layer (OSM data). These bus stops do not lie directly on the lines (see screenshot) nor should their location be moved. I use PostGIS, pgrouting and ...
0
votes
1answer
115 views

Is there any working example for pgr_trsp ?

I'm trying to use pgrouting pgr_trsp function but result is useless. Exactly same code with pgr_dijkstra working OK and find shortest path between start and stop but with pgr_trsp it is look like ...
0
votes
1answer
54 views

an efficient way to find the pgrouting edges contained within an isochrone

So I am working with some pgrouting road network data in postgis2.0/postgresql 9.1. I am interested in routing around certain types of disasters like tornados or such. If a disaster event happens at ...
1
vote
1answer
41 views

can I add additional data to an existing pgrouting postgis database using osm2pgrouting?

This is just a simple question but I could not find the information in the documentation. If I have an existing pgrouting database table named routing, can I add additional OpenStreetMap data to this ...
4
votes
3answers
479 views

How to extract primary and secondary roads from OSM data?

After importing my country roads from OSM data, I need to create a network ( roads connecting big cities ) for use with pgRouting. For this, I need the green, blue and red ones ...
5
votes
1answer
123 views

How to filter the graph on which I want to find the shortest path

I have a large graph that contains edges of Europe. I want to calculate the shortest path between two points on this graph with pgRouting that have a function pgr_trsp for shortest path calculations. ...
1
vote
1answer
43 views

Install pgRouting on Postgres 9.1 and Win 32

I referred some documents on GIS-stackexchange and over internet regarding installation of pgRouting on Postgres v9.1 and windows 32. I am not getting the correct version of pgRouting to install. Can ...
-1
votes
1answer
89 views

how to build and install pgrouting-2.0 on postgresql-9.3 on ubutntu 12.04 Lts precise?

I try to build following instructions from this link https://github.com/pgRouting/pgrouting after downloading from the github. I have done the cmake command and there is my error output: ...
3
votes
2answers
60 views

How to deal with Roundabouts in PgRouting

Can anybody guide me to to deal with roundabouts in pgrouting?? I have some roundabouts in my road network and when i try to make route from one point to another, it gives me wrong direction where it ...
1
vote
0answers
23 views

Use pgRouting with a PaaS

Is it a way to use a postGIS/pgRouting enabled database with a PaaS like Windows Azure? If not, do you know alternatives?
0
votes
0answers
28 views

Why there is no output (path) for Dijkstra in pgrouting

I have a road network table and I am implementing pgRouting. everything was working fine previously but now there is something odd here. I am getting no route now. I am checking through sql query in ...
2
votes
1answer
120 views

assign_vertex_id:problems when creating the node ids

Before using pgrouting, I have to create the node ids. I loaded my polyline layer into PostGIS Manager: I type this in SQL query: select assign_vertex_id('split_4', 800, 'geom', 'gid') But as ...
1
vote
0answers
46 views

How to deal with direction in pgr_ksp (K shortest path)?

I am working on a android app for navigation with PostGIS and pgrouting. I have implemented pgr_dijkstra and its working fine. I am not considering direction in routing at this point and just want ...
1
vote
0answers
34 views

qGIS' Database Manager “Load as New Layer” Option Not Working

I'm trying to visualize some of my database queries on qGIS. I run a valid SQL query which returns a subset of my table that should be easily loaded as a layer. I then check "Load as new layer," ...
0
votes
2answers
132 views

pgr_dijkstra working but pgr_ksp but returning anything for the same params

The following returns a route as expected. SELECT seq, id1 AS node, id2 AS edge, cost, b.the_geom as the_geom FROM pgr_dijkstra(' SELECT gid AS id, source::integer, target::integer, ...
1
vote
2answers
56 views

Can 'Source' and 'Target' in the roads table for routing be duplicate?

I am using pgr_ksp for finding multiple paths for single source and destination. I am wondering if 'source' and 'target' in a roads table are unique or not. because when i am doing routing on my road ...
1
vote
1answer
54 views

ST_Union to merge tables containing lines?

I have to build a street network with Postgis that will be used with pgrouting. I have two tables: 1) the_network (182 lines): is a MULTILINESTRING table. Having columns road_name (varchar) / ...
0
votes
1answer
48 views

PGR_CreateTopology maintain Source and Target ID's

Is there a way to set the 'source' and 'target' manually and not have it overridden in PGR_CreateTopology()? I have a predefined node ID's (INODE, JNODE) in my table which is the same to a other ...
1
vote
1answer
76 views

Wrong order to the path

I have a query which i use to find a route between two points . Even though the route is displayed good on the map the order i get from pgrouting is wrong the query is this one SELECT rt.gid, ...
1
vote
1answer
228 views

pgrouting shortest path result in wrong order

I am using the Dijkstra shortest path algorithm to plot a route between two points using the latest version of pgrouting in postgresql 9.1 with postGIS 2.0.1. I am able to get a correct result ...
1
vote
1answer
85 views

Enabling driving distance in Pgrouting

I would like to enable pgr_drivingDistance function fo Pgrouting. I followed this manual: http://pgrouting.org/docs/1.x/install.html, but I can't execute the last step: psql -U postgres -f ...
3
votes
2answers
308 views

How to install pgrouting from source on CentOS 6.3?

I'm running into a problem once I try [cmake_dir]/bin/cmake . I get these errors: Boost headers were found here: /usr/include Output directory for libraries is set to sh: ...
0
votes
1answer
34 views

(Pgrouting) Finding the best path within some maximal length

Is it possible to find the best path (where cost is not length) with the length limit? For example, find the best path that is shorter than 10km? I currently use pgr_astar from Pgrouting to find the ...
0
votes
1answer
44 views

How to know why a pgRouting function returns “FAIL”?

I am getting a "FAIL" message back when executing pgr_createTopology on a particular table, but the reason is not obvious. Is there any way to know precisely why the function is failing? Perhaps some ...
8
votes
3answers
2k views

How to emulate Google Maps driving directions using pgRouting?

Would like to emulate google maps' driving directions functionality but use pgRouting instead. google's data over the project area & scale is quite a bit off so we want to use our own transport ...
6
votes
1answer
303 views

Route analysis in R based on the OSM transport network: possible?

I'm analysing the likely paths taken by commuters on their way to work, based on Census flow data, job density distributions and the transport network. At the moment I'm using pgRouting and the ...
0
votes
1answer
24 views

pgrouting crashes and restarts the postgresql server when searching for endpoints in 2 disjoints graphs

I have >apt-show-versions postgresql-9.1-pgrouting postgresql-9.1-pgrouting/precise uptodate 2.0.0-release-ppa1~precise2 Whenever I do a search ...
0
votes
0answers
41 views

Problem running the pgr_trsp algorithm from pgrouting

I was studying the pgRouting Documentation 2.0. I was trying to run the pgr_trsp algorithm as shown in the tutorial: SELECT seq, id1 AS node, id2 AS edge, cost FROM pgr_trsp('SELECT id, source, ...
1
vote
0answers
120 views

travel survey multi stop routing problem

I have a travel diary survey dataset that I am attempting to transform into more useful information. Currently, the data comes in the format of: Survey# , PlaceVisited#, TravelMode, TripPurpose, ...
0
votes
1answer
95 views

Multi-modal public transport Routing using pgrouting or opentripplanner

I need multi-modal public transport routing for my iPhone app and also to solve a TSP problem. I have been researching and I am unable to make a decision whether I should go with pgrouting or ...
3
votes
0answers
115 views

create minimal spanning tree using table of distances between nodes rather than TSP

I am working on a transportation (linear programming) problem. Each potential solution also requires checking the distance of approx 20,000 routes with 5 to 15 nodes per route. Calculating the ...
1
vote
0answers
100 views

Some help installing pgrouting_dd on mac os x

I hope someone may be able to help me but i've been grapling for hours trying to install pgrouting with Driving Time to no success. I have been able to build pg routing no problem. However if i ...
3
votes
0answers
257 views

Shortest distance from pgrouting with cost not being length: optimal solution

I'm using pgrouting shortest_path_astar with a complicated cost function. It gives back the edges, vertices and costs. I would like to get the total distance of this shortest path (i.e., the sum of ...
0
votes
0answers
57 views

pgrouting shortestpathfromAtoB multiple pairs

I've got to solve a shortest path problem between multiple location pairs. E.g.: A to B C to D E to F etc. These pairs are stored in a table routing_basis like hkey; A; a.lat; a.lon; B; b.lat; b.lon ...
0
votes
2answers
142 views

Unable to implement pgrouting(plugin) pgr_astar routing algorithm (shortest path) [duplicate]

I have been working on a project for indoor navigation. I made the floorplan of the building and road-map for routing purposes as shp files (using JOSM, making GeoJSON and then converting to shp file ...
1
vote
1answer
99 views

pgrouting unexpected output

Thats my ways.shp file. I loaded this to PostgreSQL DB using PostGIS shape file loader. I ran pgr_anlayzeGraph() on it and found it had a lot of isolated segments. Next I ran pgr_nodeNetwork() to ...
0
votes
1answer
45 views

How to add Routing Table Query-Result on pgrouting?

I've followed the pgrouting latest workshop http://workshop.pgrouting.org. I wanted to know how to add the routing table query-result into my webpage directly after the route showed up? regards
0
votes
3answers
162 views

What is gid in OpenStreetMap data model?

I'm using an old code written by an ex-fellow and I wonder what is GID in OSM? The gid is basically used everywhere. The project uses PostGIS and PgRouting. Any pointers to that? I know this is a ...
0
votes
1answer
59 views

Migrating to Pgrouting pgr_dijkstra?

I have a system that uses shortest_path function pgrouting 1.x. At the moment, I want to migrate to pgrouting 2. And I assume the equivalent function to shortest_path is pgr_dijkstra. (Correct?) When ...
1
vote
0answers
104 views

how to add polylines(routes from public transport) on postgresql(pgrouting) with GUI

After searching a several long time... i decide to ask here for help, im currently using ubuntu 12.04(because of compatibility) with postgresql 9.1, postgis2, pgrouting2 and qgis2.2 i need ...
4
votes
2answers
573 views

Does pgRouting support turn-by-turn routing? [duplicate]

I have route list as result of pgRouting with street names. How to get messages "Turn left", "Go along" etc ... Can pgRouting do this or I need some other source and which?
0
votes
0answers
30 views

problems using GRASS v.net and v.net.allpairs

I am using GRASS 6.4.3, and I am trying to use it to do network analysis. I have a line shapefile and a point shapefile, and here is my code(I take v.net.allpairs as my reference): v.net tc_bf25 ...
0
votes
0answers
20 views

pgrouting - possible to find route through points rather than links? [duplicate]

Probably a daft question, but... I've been looking at using pgrouting to analyse paths between start/end points, but this analysis seems only to find routes through links (edges). Is there any way ...
0
votes
0answers
34 views

display route from database(postgresql) on

For first part: Link i have postgresql9.1,postgis2,pgrouting2 and qgis2.2 this is the second part of what i need to do: Search in a database (postgresql with pgrouting) for a line from public ...
1
vote
0answers
66 views

Change The OpenLayers 3 script into openlayers 2.13

Hi all I want to change the code from pgrouting latest workshop which is used the Openlayers 3 beta to Openlayers 2.13 The code is in here http://workshop.pgrouting.org/chapters/ol3_client.html I ...
3
votes
2answers
1k views

How to get started with pgRouting and OSM?

I have followed these instructions to install postgresql and pgrouting on our ubuntu server: ...