Cypher
Cypher is a graph query language for Neo4j and AgensGraph
Gremlin
Gremlin is the graph traversal language and virtual machine of Apache TinkerPop™
Harder apoc union
Example |
---|
"But i read in this post that group by on union are not possible yet it mean that cypher is less powerful than gremlin" from question Cypher union group by sum |
"Gremlin is harder to learn but it s more powerful than cypher and apoc" from question Neo4j - Cypher vs Gremlin query language |
Others
Example |
---|
Neo4j and cypher is still faster and obviously this has no effect on the gremlin queries on neo4j but that might be just a issue with the gremlin implementation for neo4j from question Are Blueprints/Gremlin graph DB queries inherently slow? |
Gremlin execution time is 50 times more than cypher query. here is the cypher query from question Find minimum and maximum length of the edges of connected graph DB in gremlin |
Recently we noticed that cypher queries run faster than gremlin so we decided to convert our queries from question Neo4j - Issue converting gremlin query to cypher |
Aveat when you start reading you may encounter with gremlin which is a common graph query language supported by neo4j;is quite awkward and very different from cypher so if you are going with neo4j you should stick to cypher neo4j has more features and most of the development is made against neo4j from question Getting started with neo4j |
Cypher seems much more clear to me than gremlin and in general it seems that the guys in neo4j are going with cypher from question Neo4j - Cypher vs Gremlin query language |
In this case a traversal-oriented approach is best maybe gremlin is better since cypher doesn t allow you to specify traversal order from question Cypher's and Gremlin's Grammar and Semantics |
In my projects i typically use gremlin and then call cypher from within gremlin or not when i need tabular results or expressive pattern matching- both are a pain in the gremlin dsl;the neo4j team s efforts on cypher have been really impressive and it s come a long way from question Neo4j - Cypher vs Gremlin query language |