Skip to content

Instantly share code, notes, and snippets.

@cihangir
Created July 1, 2013 16:51
Show Gist options
  • Save cihangir/5902549 to your computer and use it in GitHub Desktop.
Save cihangir/5902549 to your computer and use it in GitHub Desktop.
Co-Tagged places — places related through tags Find places that are tagged with the same tags: Determine the tags for place x. What else is tagged the same as x that is not x.
START place=node:node_auto_index(name = "CoffeeShop1")
MATCH place-[:tagged]->tag<-[:tagged]-otherPlace
RETURN otherPlace.name, collect(tag.name)
ORDER BY length(collect(tag.name)) DESC, otherPlace.name
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment