How to find a shop/amenity near another shop/amenity with the same name?

Hi !

I begin in using overpass turbo and i’d like to find a shop, amenity or other which is near (for exemple, around 5km) another shop, amenity or other with the same name

It’s OK to find a node near another node but I dont’t find how to filter by same name

PS : Sorry for my approximate english, I’m french… ^^

by continuing to search, I think I found the answer to my need :slight_smile:

node[“shop”=“hairdresser”]({{bbox}})->.a;
foreach.a->.elem(
node.a(around.elem:5000)
(if:is_tag(“name”)&&t[“name”]==elem.u(t[“name”]));
(._; - .elem;);
out;
);