[OSM-talk] low resource osm xapi instance
Ian
ian.dees at gmail.com
Thu May 26 03:57:12 BST 2011
On Tuesday, May 24, 2011 9:32:06 AM UTC-5, Ian wrote:
>
> On Tuesday, May 24, 2011 7:38:25 AM UTC-5, Phil! Gold wrote:
>>
>> * Robin Paulson <robi... at gmail.com> [2011-05-24 11:31 +1200]:
>> > this is my query:
>> >
>> http://open.mapquestapi.com/xapi/api/0.6/relation[route=bus][ref=010][bbox=-174.327,-37.236,175.324,-36.519]
>>
>> Everything I've read about XAPI and JXAPI has said that only one predicate
>> is supported, aside from the bbox predicate. It's possible that you're
>> getting all the bus routes within that bbox.
>>
> JXAPI allows multiple predicates, but they are currently OR'd rather than
> AND'd like I meant them to be. The above query is akin to saying "give me
> all relations with route=bus OR ref=010 OR in bbox=...".
>
I just pushed some code out (and deployed to jxapi.osm.org) that fixes this.
You can specify multiple tag predicates and they will be AND'd:
[route=bus][ref=010] = (route=bus) AND (ref=010)
[route=bus|foo][ref=010] = ((route=bus) OR (route=foo)) AND (ref=010)
>
> And yes, bbox'd relation queries aren't quite working. In this particular
> case I would suggest that you query for relation[ref=010] (since it is
> likely to return the fewest results) and use JOSM or similar to filter out
> what you're looking for.
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/talk/attachments/20110525/2087d0a1/attachment.html>
More information about the talk
mailing list