I have a problem with my cypher query :
start mag=node(1387),f=node(53)
MATCH mag-[:MAGASINS]->t-[:CONTAINS_SF]->sf1-[:IN_FAMILLY]->f
WITH distinct t,f
MATCH t-[:CONTAINS_SF]->sf2-[:IN_FAMILLY]->f1
WITH f,f1,sf2,t
WHERE f<>f1
return sf2,count(distinct t) as count
order by count desc
limit 15
this query takes actually 600ms with just 70k nodes, the target number of nodes is 10M
my jvm args : -XX:+UseConcMarkSweepGC -XX:+CMSClassUnloadingEnabled -Xmx5020m
my dev laptop : core i7, ssd, 16go
can you help my for reduce execution time ? Thanks :) Regards Charles.
My neo4j version : 1.9.1 os : mac os 10.8 jdk orcacle 1.7