Pages

Monday, July 18, 2016

Querying Your Neo4j Graph Database

There are different ways for querying, storing, managing and retrieving data in the Neo4j graph database. For a majority of users querying with Cypher is a great experience when it comes down to performing efficient and effective graph database traversals and interactions within the graph data model. For specific applications that entail further control on how graphs can be stored and queried in high performance, multi-threaded manner, a native Java API offers low-level access to graph database for granular control over the traversal and retrieval from the Neo4j graph database. When making use of the Java API, you’ll realize that you’re given great freedom and flexibility to communicate to the Neo4j graph database on how to best query your data for optimal results.

Querying with Cypher

The Cypher query language is an innovative SQL-like syntax designed for graphs that takes a more declarative approach. That means, you can tell Neo4j what you desire — not based on how to acquire it. When running a Cypher query, you’re expressing to the graph database what you need from it. In return, Neo4j has a compiler that translates the query into an executable plan describing data operation sets. The plan is conveniently arranged in a way that the obtained data from the graph is processed in a manner for each operation until a result is returned from the Cypher query.
The usual way for communicating with Neo4j consists of sending a Cypher query and parameters via an initiated POST request to the Neo4j database server. Frameworks or libraries managing wrappers around the REST API Neo4j methods from a programming language are called “drivers.” These drivers function by moving numerous queries and results over the network. Neo4j then operates by making further translation of the declarative syntax of Cypher into an executable plan.

Cypher Querying Supported by Major Language Drivers

Neo4j currently offers driver support for major programming languages. These include Python, Ruby many others. These language drivers make use of the same APIs and are conveniently made available. Thanks largely to the Neo4j community, there are Neo4j drivers present in almost all major programming language with a

Read More......

No comments:

Post a Comment