Does anyone have any experience with graph databases, like the intriguingly
named "Neo4j"?  See http://www.neo4j.org/ .

Some queries apparently look like this:

*Directors who acted in movies they also directed:*
START d=node(*)
MATCH (d)-[:DIRECTED]->(m)<-[:ACTED_IN]-(d)
RETURN d.name, m.title;

*Characters in "the matrix" movie:*
START matrix=node:node_auto_index(title="The Matrix")
MATCH (matrix)<-[r:ACTED_IN]-()
RETURN r.roles;

*The five busiest actors:*
START a=node(*)
MATCH (a)-[:ACTED_IN]->(m)
RETURN a.name, count(m)
ORDER BY count(m) DESC
LIMIT 5;


-- 
Devon McCormick, CFA
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to