Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Is it possible to search objects in a changeset ? #162
First of all: filtering on or querying of changesets is not possible at this time.
Maybe you should check out achavi, which works with a combination of OSM main db and overpass:
Step 1: Request Changeset metadata
<?xml version="1.0" encoding="UTF-8"?> <osm version="0.6" generator="OpenStreetMap server" copyright="OpenStreetMap and contributors" attribution="http://www.openstreetmap.org/copyright" license="http://opendatacommons.org/licenses/odbl/1-0/"> <changeset id="27183569" user="FahRadler" uid="344561" created_at="2014-12-02T16:36:28Z" closed_at="2014-12-02T17:40:02Z" open="false" min_lat="49.2351097" min_lon="6.7306185" max_lat="49.2734277" max_lon="6.7979623" comments_count="0"> <tag k="source" v="Bing"/> <tag k="created_by" v="JOSM/1.5 (7643 de)"/> <tag k="comment" v="Addition from Bing / Fieldwork"/> </changeset> </osm>
Step 2: Use changeset metadata to request changes in bbox in this timeframe
bbox -> 6.7306185,49.2351097,6.7979623,49.2734277
I believe this is not 100% accurate if some other user happens to do some changes in the same timeframe/bbox, as overpass will only return the last change in that timeframe. Maybe @nrenner can comment on this?
In addition to that, @drolbr is also working on tool support in this area iirc, but this is not yet (officially) available.
But technically it is possible with date settings ? So maybe Roland could implement search by chanegeset in the future ?
The problem with date is, that a changeset usually covers a timeframe of several seconds to hours with a number of changes (could be up to 2000 iirc). Date however looks at a point in time only.
Details for a single changeset are already provided by the main api: example http://www.openstreetmap.org/api/0.6/changeset/27183569/download (takes a while to load).
I still don't know what your use case is, could you elaborate a bit more, giving some more concrete examples?
Step 3 in achavi is to filter the result by the changeset id, including referenced objects.
You're right, this does not really work when an object is modified by multiple changesets in the same timeframe/bbox. Don't know how often this actually occurs and what to do about it.
I have made a changeset that was reversed. I would like to get the iDs of theses objects to build some queries : how many objects by country with tags xx=yy, and so on…
I could do that with JOSM (with the reverse changeset plugin) but I prefer to make a query with Overpass turbo (see map and see datas in XML without the risk to alter them).