Can you use latest version of Neo4j (i.e. 2.2.0-M03) ? It's not yet officially released but if you don't need it production ready yet, then it should do. Importing in it is a real doddle: http://neo4j.com/docs/2.2.0-M03/import-tool-examples.html Basically, you prepare CSV files with headers - (at least) 1 file for nodes, and 1 file for relationships. Nodes (even if only with id on them) have to be created for the relationships, otherwise you'll get errors. Then you run the files through a command line tool which is distributed as part of the Neo4j release. Sorted. Oh, and it's SUPER fast too. :)
Hope this helps. On Tuesday, February 3, 2015 at 8:18:39 AM UTC, Jesse Liu wrote: > > Hi, All, > > I'm a beginner of graph database Neo4J. > Now I need to import the data from Oracle to Neo4j. > > First, I'll describe my application scenario. > > I have just one oracle table with more than 100 million rows. > The table desc is: > id1 varchar, id2 varchar, relation_properpy int. > > id1 and id2 are primary key. > > The oracle server and Neo4J server are set up on the same machine. > > Now how I can create nodes for each id and one directed relationship > between id1 and id2 for each row? > > As far as I know, there are three ways to do this: > 1. Java Rest JDBC API > I've write a code demo and found it's too slow: 100,00 rows per minute. > Besides, it's not easy to establish a Java Environment in > > 2. Python Embedded. > I haven't write test code right now, but I think it's not better than Java. > > 3.Batch Insert > Export the data from oracle as CSV file; > Import the CSV data into Neo4J using Cypher. > I believe it's the fastest way to import data. However, I don't know how > to do this. All the demo I've seen on the Internet is about adding nodes > but without adding relationships with specific properties. > > I wonder is there anybody encounter such scenario? Can you give me some > advises? Or is there any better solution to import data? > > Thank you very much! > > Jesse > Feb 3rd, 2015 > -- You received this message because you are subscribed to the Google Groups "Neo4j" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
