openCypher* against any Relational Database | by Victor Morgante | Jul, 2023

Relational Databases as Graph Databases = Mindful (openCypher-2-SQL)

Image by author. Yin Yang Moon. Modification of Royalty Free Photo by Syed Ahmad on Unsplash

A limited subset of openCypher graph queries over any relational database is the Mindful initiative. The queries are read-only and without metagraph queries at this stage. Mindful is a closed-source modification of Microsoft’s openCypher to SQL transpiler under the MIT license, and where Mindful generates SQL to operate over any relational/SQL database.

With that in mind…let us begin by understanding the scope…

“Any relational database” in the context of Mindful means that openCypher queries are converted to SQL that targets any actual relational database, rather than relational databases that have to have specially modified tables for graph-type-queries or that inject data as JSON into fields and performing graph-like queries over that JSON data.

openCypher queries are converted to SQL to run against any stock-standard relational database.

Applicability to your business — The Data Science

You may have an existing data warehouse, semantic layer or database that is a relational in nature and that uses SQL as the primary query language…and you want to query your data assets using graph queries.

Conversely you may have an urgent need to migrate from your existing graph database to a relational/SQL based database and need tools for the data migration testing and implementation. Mindful, an openCypher-to-SQL transpiler is designed to be the tool that you use to achieve your aims.

Extant implementations of graph queries over relational databases require special tables for effective node types and edge types (say tables with single column primary keys). The Mindful implementation allows you to run filter openCypher queries over your relational database where your tables have multi-column primary keys.

In this article, we expose how this can be done with no risk to your existing relational data stack, by adopting a data science strategy where meta-information about the homomorphic graph structure of your relational data is stored within JSON in the comments section of your DDL. For instance, ORACLE, SQL Server…

Source link

Leave a Comment