【问题标题】:How to fix the error "Neo.ClientError.Statement.SemanticError: Cannot merge node using null property value for name"?如何修复错误“Neo.ClientError.Statement.SemanticError:无法使用名称的空属性值合并节点”?
【发布时间】:2019-05-08 09:43:43
【问题描述】:

尝试加载 csv 文件但弹出错误 “Neo.ClientError.Statement.SemanticError:无法使用名称的空属性值合并节点”。这是每次都弹出的错误。

LOAD CSV WITH HEADERS FROM "file:///C:/epl1.csv" AS result
WITH result, SPLIT(result.FT, '-') AS ft, SPLIT(result.HT, '-') as ht
MERGE (a:Team {name: result.`Team 1`})
MERGE (b:Team {name: result.`Team 2`})
CREATE (a)<-[:TEAMA {score_FT: ft[0], score_HT: ht[0]}]-(g:Game {date: result.Date, round: result.Round})-[:TEAMB {score_FT: ft[1], score_HT: ht[1]}]->(b)

所有节点,关系都应该添加到数据库中。这将是加载 csv 文件的结果。

【问题讨论】:

    标签: neo4j cypher


    【解决方案1】:

    确保您的 CSV 文件的标题行实际上包含 Team 1Team 2 值。并且还要确保所有其他行实际上在相应的“列”中都有值。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2016-09-02
      • 1970-01-01
      • 2019-01-21
      • 2020-10-24
      • 1970-01-01
      • 2021-04-19
      相关资源
      最近更新 更多