🎉Community Raffle - Win $25

An exclusive raffle opportunity for active members like you! Complete your profile, answer questions and get your first accepted badge to enter the raffle.
Join and Win

Connecting neo4j graph database to RapidMiner

User: "batstache611"
New Altair Community Member
Updated by Jocelyn

Has anyone tried to connect neo4j with RapidMiner before? There is very little to read on this subject from google searches. There are jdbc drivers available for neo4j but I'm not exactly sure how to get RapidMiner to use those drivers to connect to the database. This is the link to neo4j jdbc drivers -

 

http://neo4j-contrib.github.io/neo4j-jdbc/

 

Thank you.

Find more posts tagged with

Sort by:
1 - 3 of 31
    User: "Thomas_Ott"
    New Altair Community Member

    I've never done this but I would follow: http://docs.rapidminer.com/server/administration/creating-connections/creating-db-conns.html

     

    I believe one our Wisdom presenters (Rel8ted) did connect Neo4j to RapidMiner.

    User: "batstache611"
    New Altair Community Member
    OP

    Thank you Thomas,

     

    I sent them an email (info@rel8ed.to) however one of their data analysts replied saying that while they use neo4j, they do not use it from inside RapidMiner...

    User: "luc_bartkowski"
    New Altair Community Member

    To connect RapidMiner to Neo4j use the following process using the Neo4j JDBC/Bolt driver.

     

    1) In RapidMiner Connections menu: select "Manage Database Drivers"

     

    2) Add a "Neo4j" Database driver like in the following picture

     

    RM JDBC DB driver.jpg

    JDBC Bolt connections to Neo4j are supported from Neo4j version 3 and onwards.

    See https://github.com/neo4j-contrib/neo4j-jdbc

     

    3) Drag and drop the "Read Database" operator in the RapidMiner process as shown in the following picture.

    Please note that in the "Read Database Parameters" tab I selected the previously defined/named "Neo4j" database driver as the "connection" Parameter.

    RM Read Database (Neo4j jdbc).jpg

     

    4) Select in the "Read Database Parameters" tab the "Build SQL Query" button.

     

    5) Insert a Cypher query as a (pass through) "SQL Query" like in the following picture.
    Please note that in my Neo4j graph database "Organization" is a Node label and "guid" a Node property.

    Replace these with your own Node labels and properties.


    RM JDBC SQL query.jpg

     

    6) Select in RapidMiner "Run current process"(F11).

    You should see a resultset as demonstrated in the following picture.

    You don't have to enable "Beta Mode" in RapidMiner as shown in the picture. "Beta Mode" is shown in the picture because I was previously experimenting with RapidMiner beta functionality (H2O operators) in RapidMiner.

     

    RM JDBC resultset.jpg

     

    That's all!

    Now you can use Neo4j Cypher MATCH/RETURN resultsets as input for RapidMiner operators/processes.

    Please note that the resultset is a flattened table created from the Neo4j Cypher MATCH/RETURN subgraph. The graph structure is gone, it's flattened into a table. 

    The graph structure is gone, it's flattened into a table formatted resultset.