What was the output of the import? You should use labels for the match too.
And created indexes on :Female(id) and :Male(id) Do your run the tests from the shell? Michael Am 08.05.2014 um 23:52 schrieb Eric Lin <[email protected]>: > I want to import data to Neo4j and follow the instruction in below link: > > https://docs.google.com/spreadsheet/ccc?key=0Ah0qwaznhrupdF9kaDZDNWViM05UeVBfdTJmcHpQckE&usp=sharing)#gid=3 > > I can import data successfully, but when I use Cypher to query such as match > (n) return n;, the result is null... > > > > Below are the contents of data and properties setting: > > 1.Instruction > > cat import.txt | bin/neo4j-shell -config conf/neo4j.properties -path > data/graph.db > 2.import.txt > > BEGIN > create (n:Female {id:1, name:'Amada Emory'}); > create (n:Female {id:2, name:'Rana Seely'}); > create (n:Female {id:3, name:'Detra Thatcher'}); > create (n:Female {id:4, name:'Melda Reza'}); > create (n:Female {id:5, name:'Shana Willems'}); > create (n:Female {id:6, name:'Sharonda Peele'}); > create (n:Female {id:7, name:'Dagny Agee'}); > create (n:Female {id:8, name:'Tisa Woodman'}); > create (n:Female {id:9, name:'Shelba Mutchler'}); > create (n:Male {id:10, name:'Anderson Spagnola'}); > create (n:Female {id:11, name:'Pamala Forward'}); > create (n:Female {id:12, name:'Melva Fairchild'}); > create (n:Male {id:13, name:'Antione Selman'}); > create (n:Female {id:14, name:'Carmelia Cali'}); > create (n:Female {id:15, name:'Fairy Daughtery'}); > create (n:Female {id:16, name:'Stefany Mcamis'}); > create (n:Male {id:17, name:'Kermit Meaney'}); > create (n:Female {id:18, name:'Williemae Dossantos'}); > create (n:Female {id:19, name:'Marth Sparling'}); > create (n:Male {id:20, name:'Jarvis Noland'}); > match (from {id:1}), (to {id:11}) create from-[:MOTHER_OF]->to; > match (from {id:1}), (to {id:12}) create from-[:MOTHER_OF]->to; > match (from {id:1}), (to {id:13}) create from-[:MOTHER_OF]->to; > match (from {id:2}), (to {id:14}) create from-[:MOTHER_OF]->to; > match (from {id:2}), (to {id:15}) create from-[:MOTHER_OF]->to; > match (from {id:2}), (to {id:16}) create from-[:MOTHER_OF]->to; > match (from {id:3}), (to {id:17}) create from-[:MOTHER_OF]->to; > match (from {id:3}), (to {id:18}) create from-[:MOTHER_OF]->to; > match (from {id:3}), (to {id:19}) create from-[:MOTHER_OF]->to; > match (from {id:10}), (to {id:20}) create from-[:FATHER_OF]->to; > match (from {id:14}), (to {id:1}) create from-[:MOTHER_OF]->to; > match (from {id:11}), (to {id:2}) create from-[:MOTHER_OF]->to; > match (from {id:11}), (to {id:3}) create from-[:MOTHER_OF]->to; > match (from {id:12}), (to {id:4}) create from-[:MOTHER_OF]->to; > match (from {id:12}), (to {id:5}) create from-[:MOTHER_OF]->to; > match (from {id:12}), (to {id:6}) create from-[:MOTHER_OF]->to; > match (from {id:17}), (to {id:7}) create from-[:FATHER_OF]->to; > match (from {id:13}), (to {id:8}) create from-[:MOTHER_OF]->to; > match (from {id:13}), (to {id:9}) create from-[:MOTHER_OF]->to; > match (from {id:20}), (to {id:1}) create from-[:FATHER_OF]->to; > COMMIT > 3.neo4j-server.properties > > ... > # location of the database directory > org.neo4j.server.database.location=data/graph.db > ... > neo4j.properties > > # Default values for the low-level graph engine > #neostore.nodestore.db.mapped_memory=25M > #neostore.relationshipstore.db.mapped_memory=50M > #neostore.propertystore.db.mapped_memory=90M > #neostore.propertystore.db.strings.mapped_memory=130M > #neostore.propertystore.db.arrays.mapped_memory=130M > > # Enable this to be able to upgrade a store from an older version > #allow_store_upgrade=true > > # Enable this to specify a parser other than the default one. > #cypher_parser_version=2.0 > > # Keep logical logs, helps debugging but uses more disk space, enabled for > # legacy reasons To limit space needed to store historical logs use values > such > # as: "7 days" or "100M size" instead of "true" > keep_logical_logs=true > > # Autoindexing > > # Enable auto-indexing for nodes, default is false > #node_auto_indexing=true > > # The node property keys to be auto-indexed, if enabled > #node_keys_indexable=id,name,type > > # Enable auto-indexing for relationships, default is false > #relationship_auto_indexing=true > > # The relationship property keys to be auto-indexed, if enabled > #relationship_keys_indexable=name,age > > # Enable shell server so that remote clients can connect via Neo4j shell. > #remote_shell_enabled=true > # Specify custom shell port (default is 1337). > #remote_shell_port=1234 > But if I Add COMMIT and BEGIN between create and match block, the node will > be added successfully, however the relationship is failed... The format of > import.txt is: > > BEGIN > ... > create (n:Male {id:20, name:'Jarvis Noland'}); > COMMIT > BEGIN > match (from {id:1}), (to {id:11}) create from-[:MOTHER_OF]->to; > ... > COMMIT > Could someone tell me why? Many thanks! > > I also post this question on stackoverflow: > > http://stackoverflow.com/questions/23556002/fail-to-import-data-to-neo4j-by-using-spreadsheet-way > > > -- > 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. -- 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.
