Neo4j 3.1.0 apoc.load.csv trouble

假装没事ソ 提交于 2019-12-24 01:09:45

问题


I keep trying to run a apoc.load.csv procedure in the newest version of Neo4j 3.1.0, and APOC 3.1.0.3.

CALL apoc.periodic.iterate('CALL apoc.load.csv("file:///data.csv", 

{sep:",", header:TRUE}) yield map ','
with {map} as map MATCH (t:Tweet{id:toFloat(map.tweet_id)})
SET t.clean_text = map.clean_text,
t.positive_score = toInt(map.nb_positive),
t.negative_score = toInt(map.nb_negative),
t.sentiment_score = toInt(map.score)',
{batchSize:5000, parallel:true})

Error: Failed to invoke procedure apoc.periodic.iterate: Caused by: org.neo4j.graphdb.QueryExecutionException: Failed to invoke procedure apoc.load.csv: Caused by: java.lang.RuntimeException: Import from files not enabled, please set apoc.import.file.enabled=true in your neo4j.conf

I have tried just running the apoc.load.csv piece and I still get the same error telling me to add the statement to my neo4j.conf file, which I have. I've even restarted my computer.

I was able to run this exact same statement successfully in Neo4j 3.0.6 and APOC 3.0.4.1, but it doesn't work since I upgraded.


回答1:


I think that this is likely a bug.

If you click on the 'star' in the browser and then under 'System' there is a link to 'Server Configuration'. Run this query to see what Neo4J thinks it has wrt setting.

Part of this looks like:

 {
        "isIs": "false ",
        "name": "apoc.export.file.enabled",
        "description": "Configuration attribute",
        "type": "java.lang.String",
        "isReadable": "true",
        "value": "true",
        "isWriteable": "false "
      },

which indicates that the file import setting is there and correctly formatted.

The question is then why isn't this being honoured? This is as much as I've been able to determine facing the same problem.



来源:https://stackoverflow.com/questions/41190251/neo4j-3-1-0-apoc-load-csv-trouble

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!