Command Line Interface (CLI)
Kùzu provides a CLI shell through which you can issue Cypher queries or CALL
commands to query
metadata. See the installation docs for instructions on how
to install the CLI and the quick start page for its basic usage.
Start the shell
Navigate to the directory where the Kùzu CLI is located and run the following command:
Where <db_path>
is the directory for the database files.
This path can point to an existing database or a yet-to-be-created directory, in which case
Kùzu will automatically create the directory and initialize an empty database for you.
You can view the additional shell startup flags by running ./kuzu -h
.
Shell commands
Once you start the shell, you can issue Cypher queries as shown in the get started section, or call any of the shell commands listed below.
:help
Show built-in command list within the Kùzu shell.
:clear
Clear shell. Alternatively, you can use Ctrl + L
to clear the shell.
:quit
Exit from shell. Alternatively, you can use Ctrl + D
to exit the shell.
:max_rows [max_rows]
Set maximum number of rows for display. 0 defaults to 20.
:max_width [max_width]
Set maximum width in characters for display. Defaults to terminal width if unable to display first and last columns.
Interrupt shell
To interrupt a running query, use Ctrl + C
in CLI. Note: We currently don’t support interrupting COPY
statement.
Non-interactive usage
To read and process a file in non-interactive mode, pipe the file content to the CLI.