Manage queries

List all running queries

The procedure for listing queries, dbms.listQueries(), is replaced by the command for listing transactions, SHOW TRANSACTIONS. This command returns information about the currently executing query in the transaction. For more information on the command, see the Cypher manual → SHOW TRANSACTIONS command.

Terminate queries

Queries are terminated by terminating the transaction on which they are running. This is done using the TERMINATE TRANSACTIONS transactionIds command. The transactionIds can be found using the SHOW TRANSACTIONS command.

The TERMINATE TRANSACTION privilege determines what transactions can be terminated. However, the current user can always terminate all of their own transactions.

Syntax:

TERMINATE TRANSACTIONS transactionIds

Argument:

Name Type Description

transactionIds

Comma-separated strings

The IDs of all the transactions to be terminated.

transactionIds

Single string parameter

The ID of the transaction to be terminated.

transactionIds

List parameter

The IDs of all the transactions to be terminated.

For more information on the command, see the Cypher manual → TERMINATE TRANSACTIONS command.