Edit on Github

What is a Database?

A database is the outermost container for data in a Grakn knowledge graph. As per a relational database, it is commonly known to be good practice to create a single database per application, but it is absolutely fine to create as many databases as your application needs. As a rule of thumb, it is recommended to start off with one database and create more if the requirement arises.

[Important] Databases are isolated from one another. Even when running on the same Grakn Server, it is not possible to perform operations from one database on another one.

Creating a Database

We can create a new a database via the Grakn Clients Java, Node.js and Python and Grakn Console.

Listing All Databases

We can list all databases of the running Grakn server via the Grakn Clients Node.js and Python, as well as Workbase.

Cleaning a Database

Cleaning the database, not to be confused with deletion, wipes out both the data and the schema contained within the database. We can clean a database via Grakn Console.

Deleting a Database

We can delete a database via the Grakn Clients Java, Node.js and Python.

Renaming a Database

Once we have created a database, its name can no longer be changed. The only way to achieve a renamed database is to migrate the data from the database with the old name to the newly created database.