Interesting as an exercise considering Max de Marzi shared all the code on GitHub, but completely unrelated to the breadth and depth of the Facebook Graph Search.
Original title and link: Using Treetop and Neo4j Cypher to Simulate Facebook Graph Search ( ©myNoSQL)
Very interesting answer on Quora from professor Josep Lluis Larriba Pey.
- for very lager data size (TB): Infinitegraph, DEX
- for query speed: DEX
- for transaction support: Neo4j
Original title and link: What Is the Most Promising Graph Datastore? ( ©myNoSQL)
Very good slidedeck from Max de Marzi introducing Neo4j’s Cypher query language. While you’ll have to go through the 50 slides yourself to get the details, I’ve extracted a couple of interesting bits:
- Cypher was created because Neo4j Java API was too verbose and Gremlin is too prescriptive
- SPARQL was designed for a different data model and doesn’t work very well with a graph database
- Cypher design decisions:
- ASCII-art patterns (nb: when first sawing Cypher I haven’t thought of this, but it is cool)
- external DSL
- SQL familiarity (nb: as much as it’s possible with a radically different data model and processing model)
Continue to read ➤
Romiko Derbynew comparing Gremlin and Neo4j Cypher:
- Simple graph traversals are much more efficient when using Gremlin
- Queries in Gremlin are 30-50% faster for simple traversals
- Cypher is ideal for complex traversals where back tracking is required
- Cypher is our choice of query language for reporting
- Gremlin is our choice of query language for simple traversals where projections are not required
- Cypher has intrinsic table projection model, where Gremlins table projection model relies on AS steps which can be cumbersome when backtracking e.g. Back(), As() and _CopySplit, where cypher is just comma separated matches
- Cypher is much better suited for outer joins than Gremlin, to achieve similar results in gremlin requires parallel querying with CopySplit, where as in Cypher using the Match clause with optional relationships
- Gremlin is ideal when you need to retrieve very simple data structures
- Table projection in gremlin can be very powerful, however outer joins can be very verbose
So in a nutshell, we like to use Cypher when we need tabular data back from Neo4j and is especially useful in outer joins.
Original title and link: Gremlin vs Cypher ( ©myNoSQL)
Remember how useful it was to see how MapReduce translates to SQL? In a similar vein, Andrés Taylor dives into Cypher, the Neo4j querying language introduced in Neo4j 1.4, explaining it from the perspective of an SQL person:
Unlike SQL which operates on sets, Cypher predominantly works on subgraphs. The relational equivalent is the current set of tuples being evaluated during a SELECT query.
Original title and link: Neo4j Querying for SQL People ( ©myNoSQL)