我使用的是 Debian 9.9,Neo4j 的版本是 4.0。我在使用 neo4j 浏览器创建新数据库时遇到问题。我遵循的指令是这个。
我尝试了以下 Cypher 命令:
create database myNewDatabase
Run Code Online (Sandbox Code Playgroud)
但是,会弹出这样的错误:
Neo.ClientError.Statement.NotSystemDatabaseError
Unsupported administration command: create database myNewDatabase
Run Code Online (Sandbox Code Playgroud)
请让我知道错误消息的含义以及如何解决。提前谢谢:-)
Jul*_*org 21
在Neo4j专业版的 v.4 (2020 年 2 月发布)中,可以轻松创建新数据库。 文档
在社区版中,需要破解:
1. Edit the file NEO4J_HOME\conf\neo4j.conf
2. Un-comment the line: dbms.default_database=neo4j
3. Change the neo4j to whatever database name you want for a new database. Note: names must have between 3 and 63 characters. For example: dbms.default_database=mydatabase
4. Save the file
5. (If applicable) Kill the database server, and close the browser window with the Neo4j UI
6. Start the neo4j server, and open a new browser window, pointed as usual to http://localhost:7474/
7. Both the old (default) database, "neo4j" and the one you just created will show up. However, attempting to switch between them causes an error. If a switch is desired, repeat the above steps starting from (3)
Run Code Online (Sandbox Code Playgroud)
注意:上述步骤将mydatabase 在 NEO4J_HOME\data\databases 中创建一个名为(或您使用的任何名称)的文件夹,并将填充其内容。
我个人认为在数据库之间切换是一种基本操作,Neo4j 应该让它在社区版中易于访问!