Page 1 of 1

overpass-api-request is not performed complety - particular results lead to mistakes

Posted: Wed Dec 30, 2020 5:13 pm
by say_hello
dear community

i performe some requests on overpass-turbo.eu: this runs great:

Code: Select all

[out:csv(::id,::type,::lon,::lat,amenity,name,"addr:postcode","addr:city","addr:street","addr:housenumber","contact:website",website,"contact:email")]
[timeout:600];
rel[boundary=administrative][admin_level=6][name="München"] -> .city;
(nwr[amenity=hospital][name](around.city:2000);
nwr[amenity=school][name](around.city:2000););
out center;

- with the following request via overpass-turbo.eu  i have some issues


only the last expression works - in other words only the very last expression will be performed : 
all the others are ignored

Code: Select all


    [out:csv(::id,::type,::lon,::lat,amenity,name,"addr:postcode","addr:city","addr:street","addr:housenumber","contact:website",website,"contact:email")]
    [timeout:600];
    rel[boundary=administrative][admin_level=6][name="München"] -> .city;
    (nwr[amenity=hospital][name](around.city:2000);
    nwr[amenity=school][name](around.city:2000);)/>;
    nwr[amenity=childcare][name](around.city:2000);
    nwr[amenity=kindergarten][name](around.city:2000);
    nwr[amenity=nursing_home][name](around.city:2000);
    nwr[amenity=college][name](around.city:2000);
    
    out center;

in fact: only this term will be executed: 

    nwr[amenity=college][name](around.city:2000);


this is given back: 

Code: Select all

    
    @id    @type    @lon    @lat    amenity    name    addr:postcode    addr:city    addr:street    addr:housenumber    contact:website    website    contact:email
    2354666181    node    11.5557656    48.1274889    college    EAM-Europa Akademie München - School Of International Business    80337    München    Adlzreiterstraße    6            
    3324407853    node    11.5551400    48.1264588    college    Akademie Deutsche POP    80337    München    Adlzreiterstraße    18a        http://www.deutsche-pop.de/standort/muenchen    
    3324407854    node    11.5713030    48.1285751    college    Akademie Deutsche POP    80469    München    Klenzestraße    67        http://www.deutsche-pop.de/standort/muenchen    
    4379246720    node    11.5629942    48.1469822    college    Hochschule für Politik München    80333    München    Richard-Wagner-Straße    1            
    4448465264    node    11.4461165    48.1488143    college    DEKRA Akademie GmbH                        https://www.dekra-akademie.de/de/muenchen/    
    4984543723    node    11.5998193    48.1353510    college    Münchner Volkshochschule – Einstein 28    81675    München    Einsteinstraße    28        https://www.mvhs.de/ueber-uns/standorte/gasteig-einstein-28-stadtbereich-mitte/    
    5542020160    node    11.6368555    48.0790856    college    Fakultät für Betriebswirtschaftf                            
    5542020161    node    11.6348063    48.0806016    college    Fakultät für Betriebswirtschaft                            
    5542020162    node    11.6336959    48.0810352    college    Fakultät für Betriebswirtschaft                            
    18940172    way    11.4648639    48.1127381    college    Haus A Genzentrum der LMU und Institut für Biochemie    81377    München    Feodor-Lynen-Straße    25        https://www.genzentrum.lmu.de/    
    19329687    way    11.5817581    48.1500346    college    Herzogliches Georgianum    80539    München    Professor-Huber-Platz    1        http://www.herzoglichesgeorgianum.de/Herzogliches_Georgianum/Home.html    
    27959435    way    11.5929977    48.1424114    college    Bayerische EliteAkademie    80538    München    Prinzregentenstraße    7        http://www.eliteakademie.de    
    44615795    way    11.5806579    48.1550310    college    Priesterseminar St. Johannes der Täufer                    http://www.priesterseminar-muenchen.de/        
    166433609    way    11.5888108    48.1304498    college    Collegium Carolinum                            
    867729755    way    11.6027411    48.1324959    college    Katholische Stiftungshochschule München                        https://www.ksh-muenchen.de  

 

well i wonder - there must be missin something in the request
what do you say - what goes wrong here..´



update: the following code works good - with some renewed brackets

Code: Select all

[out:csv(::id,::type,::lon,::lat,amenity,name,"addr:postcode","addr:city","addr:street","addr:housenumber","contact:website",website,"contact:email")]
    [timeout:600];
    rel[boundary=administrative][admin_level=6][name="München"] -> .city;
    (
    nwr[amenity=hospital][name](around.city:200);
    nwr[amenity=school][name](around.city:200);
    nwr[amenity=childcare][name](around.city:200);
    nwr[amenity=kindergarten][name](around.city:200);
    nwr[amenity=nursing_home][name](around.city:200);
    nwr[amenity=college][name](around.city:200);
    );
    
    out center;

Re: overpass-api-request is not performed complety - particular results lead to mistakes

Posted: Wed Dec 30, 2020 5:19 pm
by timkb4cq
Mismatched parentheses?

Code: Select all

(nwr[amenity=hospital][name](around.city:2000);
    nwr[amenity=school][name](around.city:2000);)/>;
    nwr[amenity=childcare][name](around.city:2000);
    nwr[amenity=kindergarten][name](around.city:2000);
    nwr[amenity=nursing_home][name](around.city:2000);
    nwr[amenity=college][name](around.city:2000);
The intitial one (nwr isn't closed at the end.

Re: overpass-api-request is not performed complety - particular results lead to mistakes

Posted: Thu Dec 31, 2020 1:37 pm
by Fredster
If you're the same guy I've seen on other forums, you've been asking about this same topic for at least 5 yrs now. Learned anything in that time that would let you figure out your own very simple problems?