Find places that people also like who favorite this place:
Query.
START place=node:node_auto_index(name = "CoffeeShop1") MATCH place<-[:favorite]-person-[:favorite]->stuff RETURN stuff.name, count(*) ORDER BY count(*) DESC, stuff.name
The list of places that are favorited by people that favorited the start place.
Find places that are tagged with the same tags:
Query.
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
This query returns other places than CoffeeShop1 which share the same tags; they are ranked by the number of tags.
Result
otherPlace.name | collect(tag.name) |
---|---|
3 rows | |
|
|
|
|
|
|
Copyright © 2014 Neo Technology