Search code snippets, questions, articles... Chrome Extension

Get all nodes with same label using label name Cypher query neo4j

To get all nodes that have the same label from neo4j graph DB, you can use the below Cypher query.
MATCH (m:Movie)
RETURN m
Best JSON Validator, JSON Tree Viewer, JSON Beautifier at same place. Check how cool is the tool

Here, we are getting all nodes that have label named 'Movie'. The Cypher query will return all the nodes assigned to the Movie label.

MATCH (m:Movie)
RETURN m.title
Here we are getting all nodes with label Movie and return movie title from those nodes.
MATCH (m:Movie)
RETURN m
LIMIT 10
In the above Cypher query, we are returning 10 nodes that matched with the label 'Movie'.
Was this helpful?
0 Comments
Join Devsheet Ask a Question