[pgrouting-users] Ignore Vertex Not Found Error

Elijah Meeks emeeks at stanford.edu
Tue Oct 2 21:04:12 PDT 2012


How does one set it so that a target or source vertex not found simply results in an empty response (or some other response) and not not an error? I'm trying to see if there are routes between X and Y with Z roads turned off and I'd like to do it as a single query where I get the distance in the case that there are routes and a 0 or -999 or something else in the case that there is no route.

I know I could use the 1tomany implementation and just give it a single value in the array, but I'd prefer to use the standard shortest_path().

Thanks,
Elijah

************
Elijah Meeks
http://dhs.stanford.edu
Digital Humanities Specialist
Academic Computing Services
Stanford University
emeeks at stanford.edu
(650)387-6170



More information about the Pgrouting-users mailing list