Procedures

This page provides a complete reference to Neo4j’s built-in procedures.

It also lists current deprecated procedures and the procedures removed in Neo4j 5, along with their replacements.

The available procedures on a server depends on several factors:

  • Neo4j Enterprise Edition provides a larger set of procedures than Neo4j Community Edition.

  • Neo4j’s APOC Core library and GenAI plugin are installed by default on Aura instances, but have to be installed separately on on-prem servers.

  • Cluster members have procedures that are not available in standalone mode.

To check which procedures are available in your Neo4j DBMS, use the Cypher command SHOW PROCEDURES:

List available procedures with default output columns
SHOW PROCEDURES
List available procedures with full output columns
SHOW PROCEDURES YIELD *

Some procedures can only be run by users with Admin privileges. Specifically, either the EXECUTE ADMIN PROCEDURES privilege or both the EXECUTE PROCEDURES and EXECUTE BOOSTED PROCEDURES privileges. These procedures are labeled with Admin Only.

For more information, see the EXECUTE privileges section.

Authentication and authorization

For more information, see Authentication and authorization.

dbms.security.clearAuthCache()

Details

Syntax

dbms.security.clearAuthCache()

Description

Clears authentication and authorization cache.

Mode

DBMS

dbms.showCurrentUser()

Details

Syntax

dbms.showCurrentUser() :: (username, roles, flags)

Description

Show the current user.

Return arguments

Name

Type

Description

username

STRING

The name of the current user.

roles

LIST<STRING>

The roles assigned to the current user.

flags

LIST<STRING>

The flags set on the current user.

Mode

DBMS

Background job management

For more information, see Manage background jobs.

dbms.scheduler.failedJobs()

Details

Syntax

dbms.scheduler.failedJobs() :: (jobId, group, database, submitter, description, type, submitted, executionStart, failureTime, failureDescription)

Description

List failed job runs. There is a limit for amount of historical data.

Return arguments

Name

Type

Description

jobId

STRING

The id of the failed job.

group

STRING

The category of the failed job.

database

STRING

The name of the database the job failed in.

submitter

STRING

The creator of the failed job.

description

STRING

Information about the failed job.

type

STRING

The interval of the failed job.

submitted

STRING

The submission time of the failed job.

executionStart

STRING

The start time of the failed job.

failureTime

STRING

The failure time of the failed job.

failureDescription

STRING

Information about the job failure.

Mode

DBMS

This procedure is not considered safe to run from multiple threads. It is therefore not supported by the parallel runtime (introduced in Neo4j 5.13). For more information, see the Cypher Manual → Parallel runtime.

dbms.scheduler.groups()

Details

Syntax

dbms.scheduler.groups() :: (group, threads)

Description

List the job groups that are active in the database internal job scheduler.

Return arguments

Name

Type

Description

group

STRING

The name of the job group.

threads

INTEGER

The number of active threads in that job group.

Mode

DBMS

This procedure is not considered safe to run from multiple threads. It is therefore not supported by the parallel runtime (introduced in Neo4j 5.13). For more information, see the Cypher Manual → Parallel runtime.

dbms.scheduler.jobs()

Details

Syntax

dbms.scheduler.jobs() :: (jobId, group, submitted, database, submitter, description, type, scheduledAt, period, state, currentStateDescription)

Description

List all jobs that are active in the database internal job scheduler.

Return arguments

Name

Type

Description

jobId

STRING

The id of the job.

group

STRING

The category of the job.

submitted

STRING

The submission time of the job.

database

STRING

The name of the database the job is in.

submitter

STRING

The creator of the job.

description

STRING

Information about the job.

type

STRING

The interval of the job.

scheduledAt

STRING

The start time of the job.

period

STRING

The interval for jobs run periodically.

state

STRING

The state of the job: ('EXECUTING', 'SCHEDULED').

currentStateDescription

STRING

A description of the job state.

Mode

DBMS

This procedure is not considered safe to run from multiple threads. It is therefore not supported by the parallel runtime (introduced in Neo4j 5.13). For more information, see the Cypher Manual → Parallel runtime.

Change Data Capture (CDC)

For more information, see the CDC documentation.

cdc.current()

Details

Syntax

cdc.current() :: (id)

Description

Returns the current change identifier that can be used to stream changes from.

Return arguments

Name

Type

Description

id

STRING

The change identifier.

Mode

READ

Replaced by

db.cdc.current()

cdc.earliest()

Details

Syntax

cdc.earliest() :: (id)

Description

Returns the earliest change identifier that can be used to stream changes from.

Return arguments

Name

Type

Description

id

STRING

The change identifier.

Mode

READ

Replaced by

db.cdc.earliest()

cdc.query()

Details

Syntax

cdc.query([ from selectors ]) :: (id, txId, seq, metadata, event)

Description

Query changes happened from the provided change identifier.

Input arguments

Name

Type

Description

from

STRING

The change identifier to query changes from.

selectors

LIST<MAP>

An optional list of selectors to filter out changes.

Return arguments

Name

Type

Description

id

STRING

The change identifier for this change event. Used to continue querying from this change event.

txId

INTEGER

A number identifying which transaction the change happened in, unique in combination with seq.

seq

INTEGER

A number used for ordering changes that happened in the same transaction.

metadata

MAP

Metadata from the transaction that caused this change event.

event

MAP

The retrieved changes on the affected entity.

Mode

READ

Replaced by

db.cdc.query()

db.cdc.current()

Details

Syntax

db.cdc.current() :: (id)

Description

Returns the current change identifier that can be used to stream changes from.

Return arguments

Name

Type

Description

id

STRING

The change identifier.

Mode

READ

db.cdc.earliest()

Details

Syntax

db.cdc.earliest() :: (id)

Description

Returns the earliest change identifier that can be used to stream changes from.

Return arguments

Name

Type

Description

id

STRING

The change identifier.

Mode

READ

db.cdc.query()

Details

Syntax

db.cdc.query([ from selectors ]) :: (id, txId, seq, metadata, event)

Description

Query changes happened from the provided change identifier.

Input arguments

Name

Type

Description

from

STRING

The change identifier to query changes from.

selectors

LIST<MAP>

An optional list of selectors to filter out changes.

Return arguments

Name

Type

Description

id

STRING

The change identifier for this change event. Used to continue querying from this change event.

txId

INTEGER

A number identifying which transaction the change happened in, unique in combination with seq.

seq

INTEGER

A number used for ordering changes that happened in the same transaction.

metadata

MAP

Metadata from the transaction that caused this change event.

event

MAP

The retrieved changes on the affected entity.

Mode

READ

Cluster management

For more information, see Clustering.

dbms.cluster.checkConnectivity()

Details

Syntax

dbms.cluster.checkConnectivity([ port-name server ]) :: (serverId, name, address, mode-constraint, port-name, port-address, result)

Description

Check the connectivity of this instance to other cluster members. Not all ports are relevant to all members. Valid values for 'port-name' are: [CLUSTER, INTRA_BOLT, RAFT]

Input arguments

Name

Type

Description

port-name

STRING

The name of the port: ('CLUSTER', 'RAFT').

server

STRING

The id of the server to check connectivity of.

Return arguments

Name

Type

Description

serverId

STRING

The id of the checked server.

name

STRING

name :: STRING

address

STRING

address :: STRING

mode-constraint

STRING

The instance mode constraint of the server.

port-name

STRING

The name of the checked port.

port-address

STRING

The address of the checked port.

result

STRING

Whether the check was successful or not.

Mode

DBMS

dbms.cluster.cordonServer()

Details

Syntax

dbms.cluster.cordonServer(server)

Description

Mark a server in the topology as not suitable for new allocations. It will not force current allocations off the server. This is useful when deallocating databases when you have multiple unavailable servers.

Input arguments

Name

Type

Description

server

STRING

The name or id of the server to be cordoned.

Mode

WRITE

Required provileges

SERVER MANAGEMENT

Before Neo4j 5.23, the procedure dbms.cluster.cordonServer() can be run only by users with Admin privileges. Since Neo4j 5.23, it can be run with the SERVER MANAGEMENT privilege. It will still run with the Admin privilege, but that should be considered deprecated.

dbms.cluster.moveToNextDiscoveryVersion()

Details

Syntax

dbms.cluster.moveToNextDiscoveryVersion()

Description

The procedure triggers a switch to the next discovery service version for all known members of the cluster (as listed in the system database and discovery). For example, if the current member’s discovery version is V1_ONLY, it will switch all members to V1_OVER_V2. In case of failure, the user must manually resolve the issue.

Mode

DBMS

dbms.cluster.deallocateDatabaseFromServer()

Details

Syntax

dbms.cluster.deallocateDatabaseFromServer(server, database [, dryrun ]) :: (database, fromServerName, fromServerId, toServerName, toServerId, mode)

Description

Deallocate a specific user database from a specific server.

Input arguments

Name

Type

Description

server

STRING

The id of the server to deallocate from.

database

STRING

The name of the database to deallocate.

dryrun

BOOLEAN

Set to true to dry run the procedure.

Return arguments

Name

Type

Description

database

STRING

The name of the database.

fromServerName

STRING

The name of the server.

fromServerId

STRING

The id of the server.

toServerName

STRING

The name of the server.

toServerId

STRING

The id of the server.

mode

STRING

The mode in which the database is hosted.

Mode

WRITE

Required provileges

SERVER MANAGEMENT

dbms.cluster.deallocateDatabaseFromServers()

Details

Syntax

dbms.cluster.deallocateDatabaseFromServers(servers, database [, dryrun ]) :: (database, fromServerName, fromServerId, toServerName, toServerId, mode)

Description

Deallocate a specific user database from a list of servers.

Input arguments

Name

Type

Description

servers

LIST<STRING>

The ids of the servers to deallocate from.

database

STRING

The id of the database to deallocate.

dryrun

BOOLEAN

Set to true to dry run the procedure.

Return arguments

Name

Type

Description

database

STRING

The name of the database.

fromServerName

STRING

The name of the server.

fromServerId

STRING

The id of the server.

toServerName

STRING

The name of the server.

toServerId

STRING

The id of the server.

mode

STRING

The mode in which the database is hosted.

Mode

WRITE

Required provileges

SERVER MANAGEMENT

dbms.cluster.deallocateNumberOfDatabases()

Details

Syntax

dbms.cluster.deallocateNumberOfDatabases(server, number [, dryrun ]) :: (database, fromServerName, fromServerId, toServerName, toServerId, mode)

Description

Deallocate a number of user databases from a specific server.

Input arguments

Name

Type

Description

server

STRING

The id of the server to deallocate from.

number

INTEGER

The number of databases to deallocate.

dryrun

BOOLEAN

Set to true to dry run the procedure.

Return arguments

Name

Type

Description

database

STRING

The name of the database.

fromServerName

STRING

The name of the server.

fromServerId

STRING

The id of the server.

toServerName

STRING

The name of the server.

toServerId

STRING

The id of the server.

mode

STRING

The mode in which the database is hosted.

Mode

WRITE

Required provileges

SERVER MANAGEMENT

dbms.cluster.protocols()

Details

Syntax

dbms.cluster.protocols() :: (orientation, remoteAddress, applicationProtocol, applicationProtocolVersion, modifierProtocols)

Description

Overview of installed protocols

Return arguments

Name

Type

Description

orientation

STRING

Direction of the protocol (inbound or outbound).

remoteAddress

STRING

The socket address this protocol is available on.

applicationProtocol

STRING

The name of the protocol.

applicationProtocolVersion

INTEGER

The version of the protocol.

modifierProtocols

STRING

Installed modifier protocols, for example, compression.

Mode

DBMS

dbms.cluster.readReplicaToggle()

Details

Syntax

dbms.cluster.readReplicaToggle(databaseName, pause) :: (state)

Description

The toggle can pause or resume read replica (deprecated in favor of dbms.cluster.secondaryReplicationDisable)

Input arguments

Name

Type

Description

databaseName

STRING

The name of the database to toggle the secondary replication process for.

pause

BOOLEAN

Whether or not to enable/disable the secondary replication process.

Return arguments

Name

Type

Description

state

STRING

The current state of the secondary replication process.

Mode

DBMS

What is it for?

You can perform a point-in-time backup, as the backup will contain only the transactions up to the point where the transaction pulling was paused. Follow these steps to do so:

  1. Connect directly to the server hosting the database in secondary mode. (Neo4j Driver use bolt:// or use the HTTP API).

  2. Pause transaction pulling for the specified database.

  3. Back up the database, see Back up an online database.

If connected directly to a server hosting a database in secondary mode, Data Scientists can execute analysis on a specific database that is paused, the data will not unexpectedly change while performing the analysis.

This procedure can only be executed on a database that runs in a secondary role on the connected server.

Pause transaction pulling for database neo4j
CALL dbms.cluster.readReplicaToggle("neo4j", true)
Resume transaction pulling for database neo4j
CALL dbms.cluster.readReplicaToggle("neo4j", false)

dbms.cluster.reallocateDatabase()

Details

Syntax

dbms.cluster.reallocateDatabase(database [, dryrun ]) :: (database, fromServerName, fromServerId, toServerName, toServerId, mode)

Description

Reallocate a specific database.

Input arguments

Name

Type

Description

database

STRING

The name of the database to reallocate.

dryrun

BOOLEAN

Set to true to dry run the procedure.

Return arguments

Name

Type

Description

database

STRING

The name of the database.

fromServerName

STRING

The name of the server.

fromServerId

STRING

The id of the server.

toServerName

STRING

The name of the server.

toServerId

STRING

The id of the server.

mode

STRING

The mode in which the database is hosted.

Mode

WRITE

Required provileges

SERVER MANAGEMENT

dbms.cluster.reallocateNumberOfDatabases()

Details

Syntax

dbms.cluster.reallocateNumberOfDatabases(number [, dryrun ]) :: (database, fromServerName, fromServerId, toServerName, toServerId, mode)

Description

Reallocate a specified number of user databases.

Input arguments

Name

Type

Description

number

INTEGER

The number of databases to reallocate.

dryrun

BOOLEAN

Set to true to dry run the procedure.

Return arguments

Name

Type

Description

database

STRING

The name of the database.

fromServerName

STRING

The name of the server.

fromServerId

STRING

The id of the server.

toServerName

STRING

The name of the server.

toServerId

STRING

The id of the server.

mode

STRING

The mode in which the database is hosted.

Mode

WRITE

Required provileges

SERVER MANAGEMENT

dbms.cluster.recreateDatabase()

Details

Syntax

dbms.cluster.recreateDatabase(database :: STRING, options = {} :: MAP)

Description

Recreates a database while keeping all RBAC settings. The procedure initiates a process, which when complete, will have synchronized and started all database instances within the cluster.

Input arguments

Name

Type

Description

database

STRING

database :: STRING

options

MAP

options = {} :: MAP

Mode

WRITE

dbms.cluster.routing.getRoutingTable()

Details

Syntax

dbms.cluster.routing.getRoutingTable(context [, database ]) :: (ttl, servers)

Description

Returns the advertised bolt capable endpoints for a given database, divided by each endpoint’s capabilities. For example, an endpoint may serve read queries, write queries, and/or future getRoutingTable requests.

Input arguments

Name

Type

Description

context

MAP

Routing context, for example, routing policies.

database

STRING

The database to get a routing table for.

Return arguments

Name

Type

Description

ttl

INTEGER

Time to live (in seconds) for the routing table.

servers

LIST<MAP>

Servers grouped by whether they are readers, writers, or routers.

Mode

DBMS

dbms.cluster.secondaryReplicationDisable()

Details

Syntax

dbms.cluster.secondaryReplicationDisable(databaseName, pause) :: (state)

Description

The toggle can pause or resume the secondary replication process.

Input arguments

Name

Type

Description

databaseName

STRING

The name of the database to toggle the secondary replication process for.

pause

BOOLEAN

Whether or not to enable/disable the secondary replication process.

Return arguments

Name

Type

Description

state

STRING

The current state of the secondary replication process.

Mode

DBMS

What is it for?

You can perform a point-in-time backup, as the backup will contain only the transactions up to the point where the transaction pulling was paused. Follow these steps to do so:

  1. Connect directly to the server hosting the database in secondary mode. (Neo4j Driver use bolt:// or use the HTTP API).

  2. Pause transaction pulling for the specified database.

  3. Back up the database, see Back up an online database.

If connected directly to a server hosting a database in secondary mode, Data Scientists can execute analysis on a specific database that is paused, the data will not unexpectedly change while performing the analysis.

This procedure can only be executed on a database that runs in a secondary role on the connected server.

Pause transaction pulling for database neo4j
CALL dbms.cluster.secondaryReplicationDisable("neo4j", true)
Resume transaction pulling for database neo4j
CALL dbms.cluster.secondaryReplicationDisable("neo4j", false)

dbms.cluster.setAutomaticallyEnableFreeServers()

Details

Syntax

dbms.cluster.setAutomaticallyEnableFreeServers(autoEnable)

Description

With this method you can set whether free servers are automatically enabled.

Input arguments

Name

Type

Description

autoEnable

BOOLEAN

Whether or not to automatically enable free servers.

Mode

WRITE

Required provileges

SERVER MANAGEMENT

Before Neo4j 5.23, the procedure dbms.cluster.setAutomaticallyEnableFreeServers() can be run only by users with the Admin privileges. Since Neo4j 5.23, it can be run with the SERVER MANAGEMENT privilege. It will still run with the Admin privilege, but that should be considered deprecated.

dbms.cluster.showParallelDiscoveryState()

Details

Syntax

dbms.cluster.showParallelDiscoveryState() :: (mode, stateComparison, v1ServerCount, v2ServerCount)

Description

Compare the states of Discovery service V1 and Discovery service V2.

Return arguments

Name

Type

Description

mode

STRING

mode :: STRING

stateComparison

STRING

stateComparison :: STRING

v1ServerCount

STRING

v1ServerCount :: STRING

v2ServerCount

STRING

v2ServerCount :: STRING

Mode

DBMS

dbms.cluster.statusCheck()

Details

Syntax

dbms.cluster.statusCheck(databases, timeoutMilliseconds) :: (database, serverId, serverName, address, replicationSuccessful, memberStatus, recognisedLeader, recognisedLeaderTerm, requester, error)

Description

Performs a rafted status check.

Input arguments

Name

Type

Description

databases

LIST<STRING>

databases :: LIST<STRING>

timeoutMilliseconds

INTEGER

timeoutMilliseconds = null :: INTEGER

Return arguments

Name

Type

Description

database

STRING

database :: STRING

serverId

STRING

serverId :: STRING

serverName

STRING

serverName :: STRING

address

STRING

address :: STRING

replicationSuccessful

BOOLEAN

replicationSuccessful :: BOOLEAN

memberStatus

STRING

memberStatus :: STRING

recognisedLeader

STRING

recognisedLeaderTerm :: INTEGER

recognisedLeaderTerm

STRING

requester :: BOOLEAN

requester

STRING

requester :: BOOLEAN

error

STRING

error :: STRING

Mode

DBMS

dbms.cluster.switchDiscoveryServiceVersion()

Details

Syntax

dbms.cluster.switchDiscoveryServiceVersion(mode)

Description

Allows you to select which discovery service should be started. Possible values are:

  • V1_ONLY — it runs only discovery service v1.

  • V1_OVER_V2 — it runs both Discovery Service V1 and Discovery Service V2, where V1 is the main service and V2 runs in the background.

  • V2_OVER_V1 — it runs both Discovery Service V1 and Discovery Service V2, where V2 is the main service and V1 runs in the background.

  • V2_ONLY — it runs only discovery service v2.

Input arguments

Name

Type

Description

mode

STRING

mode :: STRING

Mode

DBMS

dbms.cluster.uncordonServer()

Details

Syntax

dbms.cluster.uncordonServer(server)

Description

Remove the cordon on a server, returning it to 'enabled'.

Input arguments

Name

Type

Description

server

STRING

The name or id of the server to be uncordoned.

Mode

WRITE

Replaced by

ENABLE SERVER

Required provileges

SERVER MANAGEMENT

Before Neo4j 5.23, the procedure dbms.cluster.uncordonServer() can be run only by users with Admin privileges. Since Neo4j 5.23, it can be run with the SERVER MANAGEMENT privilege. It will still run with the Admin privilege, but that should be considered deprecated.

dbms.setDatabaseAllocator()

Details

Syntax

dbms.setDatabaseAllocator(allocator)

Description

With this method you can set the allocator that is responsible for selecting servers for hosting databases.

Input arguments

Name

Type

Description

allocator

STRING

The name of the allocator.

Mode

WRITE

dbms.setDefaultAllocationNumbers()

Details

Syntax

dbms.setDefaultAllocationNumbers(primaries, secondaries)

Description

With this method you can set the default number of primaries and secondaries.

Input arguments

Name

Type

Description

primaries

INTEGER

The default number of primaries.

secondaries

INTEGER

The default number of secondaries.

Mode

WRITE

dbms.showTopologyGraphConfig()

Details

Syntax

dbms.showTopologyGraphConfig() :: (allocator, defaultPrimariesCount, defaultSecondariesCount, defaultDatabase, autoEnableFreeServers)

Description

With this method the configuration of the Topology Graph can be displayed.

Return arguments

Name

Type

Description

allocator

STRING

The name of the allocator.

defaultPrimariesCount

INTEGER

The default number of primaries.

defaultSecondariesCount

INTEGER

The default number of secondaries.

defaultDatabase

STRING

The name of the default database.

autoEnableFreeServers

BOOLEAN

Whether or not to automatically enable free servers.

Mode

READ

Configuration and DBMS info

For more information, see Configuration.

dbms.checkConfigValue()

Details

Syntax

dbms.checkConfigValue(setting, value) :: (valid, message)

Description

Check if a potential config setting value is valid.

Input arguments

Name

Type

Description

setting

STRING

The name of the setting.

value

STRING

The setting value to verify.

Return arguments

Name

Type

Description

valid

BOOLEAN

Whether or not the setting value is valid.

message

STRING

Details about the outcome of the procedure.

Mode

DBMS

This procedure is not considered safe to run from multiple threads. It is therefore not supported by the parallel runtime (introduced in Neo4j 5.13). For more information, see the Cypher Manual → Parallel runtime.

dbms.components()

Details

Syntax

dbms.components() :: (name, versions, edition)

Description

List DBMS components and their versions.

Return arguments

Name

Type

Description

name

STRING

The name of the component.

versions

LIST<STRING>

The installed versions of the component.

edition

STRING

The Neo4j edition of the DBMS.

Mode

DBMS

dbms.info()

Details

Syntax

dbms.info() :: (id, name, creationDate)

Description

Provides information regarding the DBMS.

Return arguments

Name

Type

Description

id

STRING

The id of the DBMS.

name

STRING

The name of the DBMS.

creationDate

STRING

The creation date of the DBMS.

Mode

DBMS

dbms.listCapabilities()

Details

Syntax

dbms.listCapabilities() :: (name, description, value)

Description

List capabilities.

Return arguments

Name

Type

Description

name

STRING

The full name of the capability (e.g. "dbms.instance.version").

description

STRING

The capability description (e.g. "Neo4j version this instance is running").

value

ANY

The capability object if it is present in the system (e.g. "5.20.0").

Mode

DBMS

dbms.listConfig()

Details

Syntax

dbms.listConfig([ searchString ]) :: (name, description, value, dynamic, defaultValue, startupValue, explicitlySet, validValues)

Description

List the currently active configuration settings of Neo4j.

Input arguments

Name

Type

Description

searchString

STRING

A string that filters on the name of config settings.

Return arguments

Name

Type

Description

name

STRING

The name of the setting.

description

STRING

The description of the setting.

value

STRING

The set value of the setting.

dynamic

BOOLEAN

If the setting can be set dynamically or not.

defaultValue

STRING

The default value of the setting.

startupValue

STRING

The value of the setting when the database started.

explicitlySet

BOOLEAN

Whether or not the setting was explicitly set.

validValues

STRING

A description of the valid values.

Mode

DBMS

dbms.setConfigValue()

Details

Syntax

dbms.setConfigValue(setting, value)

Description

Update a given setting value. Passing an empty value results in removing the configured value and falling back to the default value. Changes do not persist and are lost if the server is restarted. In a clustered environment, dbms.setConfigValue affects only the cluster member it is run against.

Input arguments

Name

Type

Description

setting

STRING

The name of the setting.

value

STRING

The value to set.

Mode

DBMS

dbms.listPools()

Details

Syntax

dbms.listPools() :: (pool, databaseName, heapMemoryUsed, heapMemoryUsedBytes, nativeMemoryUsed, nativeMemoryUsedBytes, freeMemory, freeMemoryBytes, totalPoolMemory, totalPoolMemoryBytes)

Description

List all memory pools, including sub pools, currently registered at this instance that are visible to the user.

Return arguments

Name

Type

Description

pool

STRING

The name of the memory pool.

databaseName

STRING

The name of the database.

heapMemoryUsed

STRING

The amount of heap memory used.

heapMemoryUsedBytes

STRING

The amount of heap memory used in bytes.

nativeMemoryUsed

STRING

The amount of native memory used.

nativeMemoryUsedBytes

STRING

The amount of native memory used in bytes.

freeMemory

STRING

The amount of free memory.

freeMemoryBytes

STRING

The amount of free memory in bytes.

totalPoolMemory

STRING

The total pool memory.

totalPoolMemoryBytes

STRING

The total pool memory in bytes.

Mode

DBMS

This procedure is not considered safe to run from multiple threads. It is therefore not supported by the parallel runtime (introduced in Neo4j 5.13). For more information, see the Cypher Manual → Parallel runtime.

Connection management

For more information, see Manage connections.

dbms.listConnections()

Details

Syntax

dbms.listConnections() :: (connectionId, connectTime, connector, username, userAgent, serverAddress, clientAddress)

Description

List all accepted network connections at this instance that are visible to the user.

Return arguments

Name

Type

Description

connectionId

STRING

The id of the connection.

connectTime

STRING

The time the connection was established.

connector

STRING

The protocol of the connector.

username

STRING

The username of the connected user.

userAgent

STRING

The active agent.

serverAddress

STRING

The address of the connected server.

clientAddress

STRING

The address of the connected client.

Mode

DBMS

dbms.killConnection()

Details

Syntax

dbms.killConnection(id) :: (connectionId, username, message)

Description

Kill network connection with the given connection id.

Input arguments

Name

Type

Description

id

STRING

The id of the connection to kill.

Return arguments

Name

Type

Description

connectionId

STRING

The id of the connection killed.

username

STRING

The username of the user of the killed connection.

message

STRING

Details about the outcome of the procedure.

Mode

DBMS

dbms.killConnections()

Details

Syntax

dbms.killConnections(ids) :: (connectionId, username, message)

Description

Kill all network connections with the given connection ids.

Input arguments

Name

Type

Description

ids

LIST<STRING>

The ids of the connections to kill.

Return arguments

Name

Type

Description

connectionId

STRING

The id of the connection killed.

username

STRING

The username of the user of the killed connection.

message

STRING

Details about the outcome of the procedure.

Mode

DBMS

Database management

db.checkpoint()

Details

Syntax

db.checkpoint() :: (success, message)

Description

Initiate and wait for a new check point, or wait any already on-going check point to complete. Note that this temporarily disables the db.checkpoint.iops.limit setting in order to make the check point complete faster. This might cause transaction throughput to degrade slightly, due to increased IO load.

Return arguments

Name

Type

Description

success

BOOLEAN

Whether the checkpoint has successfully completed.

message

STRING

Details about the outcome of the procedure.

Mode

DBMS

This procedure is not considered safe to run from multiple threads. It is therefore not supported by the parallel runtime (introduced in Neo4j 5.13). For more information, see the Cypher Manual → Parallel runtime.

db.info()

Details

Syntax

db.info() :: (id, name, creationDate)

Description

Provides information regarding the database.

Return arguments

Name

Type

Description

id

STRING

The id of the database.

name

STRING

The name of the database.

creationDate

STRING

The creation date of the database.

Mode

READ

dbms.listActiveLocks()

Details

Syntax

dbms.listActiveLocks(queryId) :: (mode, resourceType, resourceId)

Description

List the active lock requests granted for the transaction executing the query with the given query id.

Input arguments

Name

Type

Description

queryId

STRING

The id of the query to check for active locks on.

Return arguments

Name

Type

Description

mode

STRING

The lock type: ('SHARED', 'EXCLUSIVE').

resourceType

STRING

The locked resource.

resourceId

INTEGER

The id of the locked resource.

Mode

DBMS

This procedure is not considered safe to run from multiple threads. It is therefore not supported by the parallel runtime (introduced in Neo4j 5.13). For more information, see the Cypher Manual → Parallel runtime.

db.listLocks()

Details

Syntax

db.listLocks() :: (mode, resourceType, resourceId, transactionId)

Description

List all locks at this database.

Return arguments

Name

Type

Description

mode

STRING

The locking mode this lock is using, either "SHARED" or "EXCLUSIVE".

resourceType

STRING

The type of resource (e.g. nodes, relationships, labels) this lock protects.

resourceId

INTEGER

The id of the resource this lock protects.

transactionId

STRING

The id of the transaction that owns this lock.

Mode

DBMS

db.ping()

Details

Syntax

db.ping() :: (success)

Description

This procedure can be used by client side tooling to test whether they are correctly connected to a database. The procedure is available in all databases and always returns true. A faulty connection can be detected by not being able to call this procedure.

Return arguments

Name

Type

Description

success

BOOLEAN

Whether or not the connection call to the database has been successful.

Mode

READ

dbms.routing.getRoutingTable()

Details

Syntax

dbms.routing.getRoutingTable(context [, database ]) :: (ttl, servers)

Description

Returns the advertised bolt capable endpoints for a given database, divided by each endpoint’s capabilities. For example, an endpoint may serve read queries, write queries, and/or future getRoutingTable requests.

Input arguments

Name

Type

Description

context

MAP

Routing context, for example, routing policies.

database

STRING

The database to get a routing table for.

Return arguments

Name

Type

Description

ttl

INTEGER

Time to live (in seconds) for the routing table.

servers

LIST<MAP>

Servers grouped by whether they are readers, writers, or routers.

Mode

DBMS

dbms.setDefaultDatabase()

Details

Syntax

dbms.setDefaultDatabase(databaseName) :: (result)

Description

Change the default database to the provided value. The database must exist and the old default database must be stopped.

Input arguments

Name

Type

Description

databaseName

STRING

The name of the database.

Return arguments

Name

Type

Description

result

STRING

Information about the default database.

Mode

WRITE

dbms.quarantineDatabase()

Details

Syntax

dbms.quarantineDatabase(databaseName, setStatus [, reason ]) :: (databaseName, quarantined, result)

Description

Place a database into quarantine or remove it from it.

Input arguments

Name

Type

Description

databaseName

STRING

The name of the database to set the quarantine status of.

setStatus

BOOLEAN

Whether or not to quarantine the database.

reason

STRING

The reason to quarantine the database.

Return arguments

Name

Type

Description

databaseName

STRING

The name of the database.

quarantined

BOOLEAN

Whether or not the database is quarantined.

result

STRING

Details about the outcome of the procedure.

Mode

DBMS

dbms.upgrade()

Details

Syntax

dbms.upgrade() :: (status, upgradeResult)

Description

Upgrade the system database schema if it is not the current schema.

Return arguments

Name

Type

Description

status

STRING

The upgrade status of the system database.

upgradeResult

STRING

Information about the upgrade outcome.

Mode

WRITE

This procedure is not considered safe to run from multiple threads. It is therefore not supported by the parallel runtime (introduced in Neo4j 5.13). For more information, see the Cypher Manual → Parallel runtime.

dbms.upgradeStatus()

Details

Syntax

dbms.upgradeStatus() :: (status, description, resolution)

Description

Report the current status of the system database sub-graph schema.

Return arguments

Name

Type

Description

status

STRING

The upgrade status of the system database.

description

STRING

Information describing the upgrade status.

resolution

STRING

Information about the steps necessary to upgrade.

Mode

READ

This procedure is not considered safe to run from multiple threads. It is therefore not supported by the parallel runtime (introduced in Neo4j 5.13). For more information, see the Cypher Manual → Parallel runtime.

GenAI and vectors

For more information, see:

db.create.setNodeVectorProperty

Details

Syntax

db.create.setNodeVectorProperty(node, key, vector)

Description

Set a vector property on a given node in a more space efficient representation than Cypher’s SET.

Input arguments

Name

Type

Description

node

NODE

The node on which the new property will be stored.

key

STRING

The name of the new property.

vector

ANY

The object containing the embedding.

Mode

WRITE

Known issue

Procedure signatures from SHOW PROCEDURES renders the vector arguments with a type of ANY rather than the semantically correct type of LIST<INTEGER | FLOAT>. The types are still enforced as LIST<INTEGER | FLOAT>.

db.create.setRelationshipVectorProperty()

Details

Syntax

db.create.setRelationshipVectorProperty(relationship, key, vector)

Description

Set a vector property on a given relationship in a more space efficient representation than Cypher’s SET.

Input arguments

Name

Type

Description

relationship

RELATIONSHIP

The relationship on which the new property will be stored.

key

STRING

The name of the new property.

vector

ANY

The object containing the embedding.

Mode

WRITE

Known issue

Procedure signatures from SHOW PROCEDURES renders the vector arguments with a type of ANY rather than the semantically correct type of LIST<INTEGER | FLOAT>. The types are still enforced as LIST<INTEGER | FLOAT>.

db.create.setVectorProperty()

Details

Syntax

db.create.setVectorProperty(node, key, vector) :: (node)

Description

Set a vector property on a given node in a more space efficient representation than Cypher’s SET.

Input arguments

Name

Type

Description

node

NODE

The node on which the new property will be stored.

key

STRING

The name of the new property.

vector

ANY

The object containing the embedding.

Return arguments

Name

Type

Description

node

NODE

The node on which the vector property was set.

Mode

WRITE

Replaced by

db.create.setNodeVectorProperty() and db.create.setRelationshipVectorProperty()

Known issue

Procedure signatures from SHOW PROCEDURES renders the vector arguments with a type of ANY rather than the semantically correct type of LIST<INTEGER | FLOAT>. The types are still enforced as LIST<INTEGER | FLOAT>.

db.index.vector.createNodeIndex()

Details

Syntax

db.index.vector.createNodeIndex(indexName, label, propertyKey, vectorDimension, vectorSimilarityFunction)

Description

Create a named node vector index for the specified label and property with the given vector dimensionality using either the EUCLIDEAN or COSINE similarity function. Both similarity functions are case-insensitive. Use the db.index.vector.queryNodes procedure to query the named index.

Input arguments

Name

Type

Description

indexName

STRING

indexName :: STRING

label

STRING

label :: STRING

propertyKey

STRING

propertyKey :: STRING

vectorDimension

INTEGER

vectorDimension :: INTEGER

vectorSimilarityFunction

STRING

vectorSimilarityFunction :: STRING

Mode

SCHEMA

As of Neo4j 5.15, vector indexes can be created with the Cypher Command CREATE VECTOR INDEX. For more information, see the Cypher Manual → Create a vector index.

db.index.vector.queryNodes()

Details

Syntax

db.index.vector.queryNodes(indexName, numberOfNearestNeighbours, query) :: (node, score)

Description

Query the given node vector index. Returns requested number of nearest neighbors to the provided query vector, and their similarity score to that query vector, based on the configured similarity function for the index. The similarity score is a value between [0, 1]; where 0 indicates least similar, 1 most similar.

Input arguments

Name

Type

Description

indexName

STRING

The name of the vector index.

numberOfNearestNeighbours

INTEGER

The size of the vector neighbourhood.

query

ANY

The object to find approximate matches for.

Return arguments

Name

Type

Description

node

NODE

A node which contains a vector property similar to the query object.

score

FLOAT

The score measuring how similar the node property is to the query object.

Mode

READ

db.index.vector.queryRelationships()

Details

Syntax

db.index.vector.queryRelationships(indexName, numberOfNearestNeighbours, query) :: (relationship, score)

Description

Query the given relationship vector index. Returns requested number of nearest neighbors to the provided query vector, and their similarity score to that query vector, based on the configured similarity function for the index. The similarity score is a value between [0, 1]; where 0 indicates least similar, 1 most similar.

Input arguments

Name

Type

Description

indexName

STRING

The name of the vector index.

numberOfNearestNeighbours

INTEGER

The size of the vector neighbourhood.

query

ANY

The object to find approximate matches for.

Return arguments

Name

Type

Description

relationship

RELATIONSHIP

A relationship which contains a vector property similar to the query object.

score

FLOAT

The score measuring how similar the node property is to the query object.

Mode

READ

genai.vector.encodeBatch()

Details

Syntax

genai.vector.encodeBatch(resources, provider, configuration) :: (index, resource, vector)

Description

Encode a given batch of resources as vectors using the named provider. For each element in the given resource LIST this returns:

  • the corresponding 'index' within that LIST,

  • the original 'resource' element itself,

  • and the encoded 'vector'.

Input arguments

Name

Type

Description

resources

LIST<STRING>

The object to transform into an embedding.

provider

STRING

The GenAI provider to use.

configuration

MAP

The provider specific settings.

Return arguments

Name

Type

Description

index

INTEGER

The index of the corresponding element in the input list.

resource

STRING

The name of the input resource.

vector

ANY

The generated vector embedding for the resource.

Mode

DEFAULT

Known issue

Procedure signatures from SHOW PROCEDURES renders the vector arguments with a type of ANY rather than the semantically correct type of LIST<INTEGER | FLOAT>. The types are still enforced as LIST<INTEGER | FLOAT>.

genai.vector.listEncodingProviders()

Details

Syntax

genai.vector.listEncodingProviders() :: (name, requiredConfigType, otionalConfigType, defaultConfig)

Description

Lists the available vector embedding providers.

Return arguments

Name

Type

Description

name

STRING

The name of the GenAI provider.

requiredConfigType

STRING

The signature of the required config map.

optionalConfigType

STRING

The signature of the optional config map.

defaultConfig

MAP

The default values for the GenAI provider.

Mode

DEFAULT

Index management

For more information, see:

db.awaitIndex()

Details

Syntax

db.awaitIndex(indexName [, timeOutSeconds ])

Description

Wait for an index to come online (for example: CALL db.awaitIndex("MyIndex", 300)).

Input arguments

Name

Type

Description

indexName

STRING

The name of the awaited index.

timeOutSeconds

INTEGER

The maximum time to wait.

Mode

READ

This procedure is not considered safe to run from multiple threads. It is therefore not supported by the parallel runtime (introduced in Neo4j 5.13). For more information, see the Cypher Manual → Parallel runtime.

db.awaitIndexes()

Details

Syntax

db.awaitIndexes([ timeOutSeconds ])

Description

Wait for all indexes to come online (for example: CALL db.awaitIndexes(300)).

Input arguments

Name

Type

Description

timeOutSeconds

INTEGER

The maximum time to wait.

Mode

READ

This procedure is not considered safe to run from multiple threads. It is therefore not supported by the parallel runtime (introduced in Neo4j 5.13). For more information, see the Cypher Manual → Parallel runtime.

db.index.fulltext.awaitEventuallyConsistentIndexRefresh()

Details

Syntax

db.index.fulltext.awaitEventuallyConsistentIndexRefresh()

Description

Wait for the updates from recently committed transactions to be applied to any eventually-consistent full-text indexes.

Mode

READ

db.index.fulltext.listAvailableAnalyzers()

Details

Syntax

db.index.fulltext.listAvailableAnalyzers() :: (analyzer, description, stopwords)

Description

List the available analyzers that the full-text indexes can be configured with.

Return arguments

Name

Type

Description

analyzer

STRING

The name of the analyzer.

description

STRING

The description of the analyzer.

stopwords

LIST<STRING>

The stopwords used by the analyzer to tokenize strings.

Mode

READ

db.index.fulltext.queryNodes()

Details

Syntax

db.index.fulltext.queryNodes(indexName, queryString [, options ]) :: (node, score)

Description

Query the given full-text index. Returns the matching nodes and their Lucene query score, ordered by score. Valid key: value pairs for the options map are:

  • 'skip' — to skip the top N results.

  • 'limit' — to limit the number of results returned.

  • 'analyzer' — to use the specified analyzer as a search analyzer for this query.

The options map and any of the keys are optional. An example of the options map: {skip: 30, limit: 10, analyzer: 'whitespace'}

Input arguments

Name

Type

Description

indexName

STRING

The name of the fulltext index.

queryString

STRING

The string to find approximate matches for.

options

MAP

{skip :: INTEGER, limit :: INTEGER, analyzer :: STRING}

Return arguments

Name

Type

Description

node

NODE

A node which contains a property similar to the query string.

score

FLOAT

The score measuring how similar the node property is to the query string.

Mode

READ

db.index.fulltext.queryRelationships()

Details

Syntax

db.index.fulltext.queryRelationships(indexName, queryString [, options ]) :: (relationship, score)

Description

Query the given full-text index. Returns the matching relationships and their Lucene query score, ordered by score. Valid key: value pairs for the options map are:

  • 'skip' — to skip the top N results.

  • 'limit' — to limit the number of results returned.

  • 'analyzer' — to use the specified analyzer as a search analyzer for this query.

The options map and any of the keys are optional. An example of the options map: {skip: 30, limit: 10, analyzer: 'whitespace'}

Input arguments

Name

Type

Description

indexName

STRING

The name of the fulltext index.

queryString

STRING

The string to find approximate matches for.

options

MAP

{skip :: INTEGER, limit :: INTEGER, analyzer :: STRING}

Return arguments

Name

Type

Description

relationship

RELATIONSHIP

A relationship which contains a property similar to the query string.

score

FLOAT

The score measuring how similar the node property is to the query string.

Mode

READ

db.resampleIndex()

Details

Syntax

db.resampleIndex(indexName)

Description

Schedule resampling of an index (for example: CALL db.resampleIndex("MyIndex")).

Input arguments

Name

Type

Description

indexName

STRING

The name of the index.

Mode

READ

This procedure is not considered safe to run from multiple threads. It is therefore not supported by the parallel runtime (introduced in Neo4j 5.13). For more information, see the Cypher Manual → Parallel runtime.

db.resampleOutdatedIndexes()

Details

Syntax

db.resampleOutdatedIndexes()

Description

Schedule resampling of all outdated indexes.

Mode

READ

This procedure is not considered safe to run from multiple threads. It is therefore not supported by the parallel runtime (introduced in Neo4j 5.13). For more information, see the Cypher Manual → Parallel runtime.

Metrics

dbms.queryJmx()

Details

Syntax

dbms.queryJmx(query) :: (name, description, attributes)

Description

Query JMX management data by domain and name. For instance, use : to find all JMX beans.

Input arguments

Name

Type

Description

query

STRING

A query for MBeans on this MBeanServer (e.g. ':,name=neo4j' for all metrics in neo4j database).

Return arguments

Name

Type

Description

name

STRING

The name of the metric.

description

STRING

The description of the metric.

attributes

MAP

A collection with the attributes (values) of that metric.

Mode

DBMS

Schema and metadata

db.schema.nodeTypeProperties()

Details

Syntax

db.schema.nodeTypeProperties() :: (nodeType, nodeLabels, propertyName, propertyTypes, mandatory)

Description

Show the derived property schema of the nodes in tabular form.

Return arguments

Name

Type

Description

nodeType

STRING

A name generated from the labels on the node.

nodeLabels

LIST<STRING>

A list containing the labels on a category of node.

propertyName

STRING

A property key on a category of node.

propertyTypes

LIST<STRING>

All types of a property belonging to a node category.

mandatory

BOOLEAN

Whether or not the property is present on all nodes belonging to a node category.

Mode

READ

This procedure is not considered safe to run from multiple threads. It is therefore not supported by the parallel runtime (introduced in Neo4j 5.13). For more information, see the Cypher Manual → Parallel runtime.

db.schema.relTypeProperties()

Details

Syntax

db.schema.relTypeProperties() :: (relType, propertyName, propertyTypes, mandatory)

Description

Show the derived property schema of the relationships in tabular form.

Return arguments

Name

Type

Description

relType

STRING

A name generated from the type on the relationship.

propertyName

STRING

A property key on a category of relationship.

propertyTypes

LIST<STRING>

All types of a property belonging to a relationship category.

mandatory

BOOLEAN

Whether or not the property is present on all relationships belonging to a relationship category.

Mode

READ

This procedure is not considered safe to run from multiple threads. It is therefore not supported by the parallel runtime (introduced in Neo4j 5.13). For more information, see the Cypher Manual → Parallel runtime.

db.schema.visualization()

Details

Syntax

db.schema.visualization() :: (nodes, relationships)

Description

Visualizes the schema of the data based on available statistics. A new node is returned for each label. The properties represented on the node include: name (label name), indexes (list of indexes), and constraints (list of constraints). A relationship of a given type is returned for all possible combinations of start and end nodes. The properties represented on the relationship include: name (type name). Note that this may include additional relationships that do not exist in the data due to the information available in the count store.

Return arguments

Name

Type

Description

nodes

LIST<NODE>

A list of virtual nodes representing each label in the database.

relationships

LIST<RELATIONSHIP>

A list of virtual relationships representing all combinations between start and end nodes in the database.

Mode

READ

This procedure is not considered safe to run from multiple threads. It is therefore not supported by the parallel runtime (introduced in Neo4j 5.13). For more information, see the Cypher Manual → Parallel runtime.

db.createLabel()

Details

Syntax

db.createLabel(newLabel)

Description

Create a label

Input arguments

Name

Type

Description

newLabel

STRING

A new label.

Mode

WRITE

db.createProperty()

Details

Syntax

db.createProperty(newProperty)

Description

Create a Property

Input arguments

Name

Type

Description

newProperty

STRING

A new property.

Mode

WRITE

db.createRelationshipType

Details

Syntax

db.createRelationshipType(newRelationshipType)

Description

Create a RelationshipType

Input arguments

Name

Type

Description

newRelationshipType

STRING

A new relationship type.

Mode

WRITE

db.labels()

Details

Syntax

db.labels() :: (label)

Description

List all labels attached to nodes within a database according to the user’s access rights. The procedure returns empty results if the user is not authorized to view those labels.

Return arguments

Name

Type

Description

label

STRING

A label within the database.

Mode

READ

db.propertyKeys()

Details

Syntax

db.propertyKeys() :: (propertyKey)

Description

List all property keys in the database.

Return arguments

Name

Type

Description

propertyKey

STRING

A property key in the database.

Mode

READ

This procedure is not considered safe to run from multiple threads. It is therefore not supported by the parallel runtime (introduced in Neo4j 5.13). For more information, see the Cypher Manual → Parallel runtime.

db.relationshipTypes()

Details

Syntax

db.relationshipTypes() :: (relationshipType)

Description

List all types attached to relationships within a database according to the user’s access rights. The procedure returns empty results if the user is not authorized to view those relationship types.

Return arguments

Name

Type

Description

relationshipType

STRING

A relationship type in the database.

Mode

READ

This procedure is not considered safe to run from multiple threads. It is therefore not supported by the parallel runtime (introduced in Neo4j 5.13). For more information, see the Cypher Manual → Parallel runtime.

Statistics and query planning

For more information, see Statistics and execution plans

db.clearQueryCaches()

Details

Syntax

db.clearQueryCaches() :: (value)

Description

Clears all query caches.

Return arguments

Name

Type

Description

value

STRING

The number of cleared query caches.

Mode

DBMS

db.prepareForReplanning()

Details

Syntax

db.prepareForReplanning([ timeOutSeconds ])

Description

Triggers an index resample and waits for it to complete, and after that clears query caches. After this procedure has finished queries will be planned using the latest database statistics.

Input arguments

Name

Type

Description

timeOutSeconds

INTEGER

The maximum time to wait.

Mode

READ

This procedure is not considered safe to run from multiple threads. It is therefore not supported by the parallel runtime (introduced in Neo4j 5.13). For more information, see the Cypher Manual → Parallel runtime.

db.stats.clear

Details

Syntax

db.stats.clear(section) :: (section, success, message)

Description

Clear collected data of a given data section. Valid sections are 'QUERIES'

Input arguments

Name

Type

Description

section

STRING

Specify 'QUERIES'.

Return arguments

Name

Type

Description

section

STRING

The section cleared.

success

BOOLEAN

Whether the section was successfully cleared.

message

STRING

Details about the outcome of the procedure.

Mode

READ

db.stats.collect()

Details

Syntax

db.stats.collect(section [, config ]) :: (section, success, message)

Description

Start data collection of a given data section. Valid sections are 'QUERIES'

Input arguments

Name

Type

Description

section

STRING

Specify 'QUERIES'.

config

MAP

A map containing a single key durationSeconds (default value of -1).

Return arguments

Name

Type

Description

section

STRING

The section collected.

success

BOOLEAN

Whether the section was successfully collected.

message

STRING

Details about the outcome of the procedure.

Mode

READ

db.stats.retrieve()

Details

Syntax

db.stats.retrieve(section [, config ]) :: (section, data)

Description

Retrieve statistical data about the current database. Valid sections are 'GRAPH COUNTS', 'TOKENS', 'QUERIES', 'META'

Input arguments

Name

Type

Description

section

STRING

A section of stats to retrieve: ('GRAPH COUNTS', 'TOKENS', 'QUERIES', 'META').

config

MAP

A map containing a single key maxInvocations (default value of 100).

Return arguments

Name

Type

Description

section

STRING

The section retrieved.

data

MAP

Data pertaining to the retrieved statistics.

Mode

READ

db.stats.retrieveAllAnonymized()

Details

Syntax

db.stats.retrieveAllAnonymized(graphToken [, config ]) :: (section, data)

Description

Retrieve all available statistical data about the current database, in an anonymized form.

Input arguments

Name

Type

Description

graphToken

STRING

The name of the graph token.

config

MAP

A map containing a single key maxInvocations (default value of 100).

Return arguments

Name

Type

Description

section

STRING

The section retrieved.

data

MAP

Data pertaining to the retrieved statistics.

Mode

READ

db.stats.status()

Details

Syntax

db.stats.status() :: (section, status, data)

Description

Retrieve the status of all available collector daemons, for this database.

Return arguments

Name

Type

Description

section

STRING

String with the message "QUERIES".

status

STRING

The status of the QueryCollector: "idle" or "collecting".

data

MAP

data :: MAP

Mode

READ

db.stats.stop()

Details

Syntax

db.stats.stop(section) :: (section, success, message)

Description

Stop data collection of a given data section. Valid sections are 'QUERIES'

Input arguments

Name

Type

Description

section

STRING

Specify 'QUERIES'.

Return arguments

Name

Type

Description

section

STRING

The stopped section.

success

BOOLEAN

Whether the section was successfully stopped.

message

STRING

Details about the outcome of the procedure.

Mode

READ

Transaction management

tx.getMetaData()

Details

Syntax

tx.getMetaData() :: (metadata)

Description

Provides attached transaction metadata.

Return arguments

Name

Type

Description

metadata

MAP

Metadata about the transaction.

Mode

DBMS

tx.setMetaData()

Details

Syntax

tx.setMetaData(data)

Description

Attaches a map of data to the transaction. The data will be printed when listing queries, and inserted into the query log.

Input arguments

Name

Type

Description

data

MAP

Metadata to attach to the transaction.

Mode

DBMS

List of deprecated procedures

Neo4j 5 contains several deprecated procedures. These procedures have been replaced either by Cypher commands or different procedures. The procedures deprecated in Neo4j 5 will be removed in the next major release of Neo4j.

See all deprecated procedures
Name Community Edition Enterprise Edition Comment

cdc.current()

No

Yes

Introduced in 5.13 Beta Deprecated in 5.17 Replaced by: db.cdc.current()

cdc.earliest()

No

Yes

Introduced in 5.13 Beta Deprecated in 5.17 Replaced by: db.cdc.earliest()

cdc.query()

No

Yes

Introduced in 5.13 Beta Admin Only Deprecated in 5.17 Replaced by: db.cdc.query()

db.create.setVectorProperty()

Yes

Yes

Introduced in 5.11 Beta Deprecated in 5.13 Replaced by: db.create.setNodeVectorProperty()

dbms.cluster.readReplicaToggle()

No

Yes

Admin Only Deprecated in 5.6.
Replaced by: dbms.cluster.secondaryReplicationDisable().

dbms.cluster.routing.getRoutingTable()

Yes

Yes

Deprecated in 5.21.
Replaced by: dbms.routing.getRoutingTable().

dbms.cluster.uncordonServer()

No

Yes

Deprecated in 5.23.
Before Neo4j 5.23, the procedure can be run only with the Admin privileges.
Replaced by ENABLE SERVER.

dbms.setDatabaseAllocator()

No

Yes

Admin Only Deprecated in 5.23

dbms.upgrade()

Yes

Yes

Admin Only Deprecated in 5.9

dbms.upgradeStatus()

Yes

Yes

Admin Only Deprecated in 5.9

List of removed procedures

Several procedures were removed with the release of Neo4j. They were functionally replaced by Cypher commands or different procedures.

See all procedures removed in Neo4j 5.0 and their replacements
Name Community Edition Enterprise Edition Replaced by

db.constraints()

Yes

Yes

SHOW CONSTRAINTS

db.createIndex()

Yes

Yes

CREATE INDEX

db.createNodeKey()

No

Yes

CREATE CONSTRAINT …​ IS NODE KEY

db.createUniquePropertyConstraint()

Yes

Yes

CREATE CONSTRAINT …​ IS UNIQUE

db.indexes()

Yes

Yes

SHOW INDEXES

db.indexDetails()

Yes

Yes

SHOW INDEXES YIELD*

db.index.fulltext.createNodeIndex()

Yes

Yes

CREATE FULLTEXT INDEX …​

db.index.fulltext.createRelationshipIndex()

Yes

Yes

CREATE FULLTEXT INDEX …​

db.index.fulltext.drop()

Yes

Yes

DROP INDEX …​

db.schemaStatements()

Yes

Yes

SHOW INDEXES YIELD * and SHOW CONSTRAINTS YIELD *

dbms.cluster.overview()

No

Yes

SHOW SERVERS

dbms.cluster.quarantineDatabase()

No

Yes

dbms.quarantineDatabase()

dbms.cluster.role()

No

Yes

SHOW DATABASES

dbms.cluster.setDefaultDatabase()

No

Yes

dbms.setDefaultDatabase

dbms.database.state()

Yes

Yes

SHOW DATABASES

dbms.functions()

Yes

Yes

SHOW FUNCTIONS

dbms.killQueries()

Yes

Yes

TERMINATE TRANSACTIONS

dbms.killQuery()

Yes

Yes

TERMINATE TRANSACTIONS

dbms.killTransaction()

Yes

Yes

TERMINATE TRANSACTIONS

dbms.killTransactions()

Yes

Yes

TERMINATE TRANSACTIONS

dbms.listQueries()

Yes

Yes

SHOW TRANSACTIONS

dbms.listTransactions()

Yes

Yes

SHOW TRANSACTIONS

dbms.procedures()

No

Yes

SHOW PROCEDURES

dbms.security.activateUser()

No

Yes

ALTER USER

dbms.security.addRoleToUser()

No

Yes

GRANT ROLE TO USER

dbms.security.changePassword()

Yes

Yes

ALTER CURRENT USER SET PASSWORD

dbms.security.changeUserPassword()

No

Yes

ALTER USER

dbms.security.createRole()

No

Yes

CREATE ROLE

dbms.security.createUser()

Yes

Yes

CREATE USER

dbms.security.deleteRole()

No

Yes

DROP ROLE

dbms.security.deleteUser()

Yes

Yes

DROP USER

dbms.security.listRoles()

Yes

Yes

SHOW ROLES

dbms.security.listRolesForUser()

No

Yes

SHOW USERS

dbms.security.listUsers()

Yes

Yes

SHOW USERS

dbms.security.listUsersForRole()

No

Yes

SHOW ROLES WITH USERS

dbms.security.removeRoleFromUser()

No

Yes

REVOKE ROLE FROM USER

dbms.security.suspendUser()

No

Yes

ALTER USER