How to delete/create databases in Neo4j?

前端 未结 12 1178
既然无缘
既然无缘 2020-12-12 11:52

Is it possible to create/delete different databases in the graph database Neo4j like in MySQL? Or, at least, how to delete all nodes and relationships of an existing graph t

12条回答
  •  感情败类
    2020-12-12 12:28

    Easiest answer is: NO

    The best way to "start over" is to

    • move to another empty data folder

    or

    • close Neo4j completely
    • empty the old data folder
    • restart Neo4j and set the empty folder as the data folder

    There is a way to delete all nodes and relationships (as described here)

    MATCH (n)
    OPTIONAL MATCH (n)-[r]-()
    DELETE n,r
    

提交回复
热议问题