UltipaDocs
Products
Solutions
Resources
Company
Start Free Trial
UltipaDocs
Start Free Trial
  • Introduction
  • GQL vs Other Languages
    • Overview
    • Node and Edge Patterns
    • Path Patterns
    • Quantified Paths
    • Questioned Paths
    • Shortest Paths
    • Cheapest Paths
    • K-Hop Traversal
    • Graph Patterns
    • Overview
    • Open Graphs
    • Closed Graphs
    • Graphs with Edge ID
    • Graph Types
    • Constraints
    • Projections
    • Storage Maintenance
    • Unique Identifiers
    • INSERT
    • INSERT OVERWRITE
    • UPSERT
    • MERGE
    • SET
    • REMOVE
    • DELETE
    • FOREACH
    • Query Composition
    • Result Table and Visualization
    • MATCH
    • OPTIONAL MATCH
    • FILTER
    • LET
    • FOR
    • ORDER BY
    • LIMIT
    • SKIP
    • CALL
    • RETURN
    • Composite Query
    • NEXT
    • All Functions
    • Element Functions
    • Path Functions
    • Aggregate Functions
    • Mathematical Functions
    • Trigonometric Functions
    • String Functions
    • List Functions
    • Datetime Functions
    • Spatial Functions
    • Null Functions
    • Utility Functions
    • Type Conversion Functions
    • Table Functions
    • Database Functions
  • Operators
  • Predicates
    • CASE
    • LET Value Expression
    • Value Query Expression
    • List Expressions
    • Index
    • Full-text Index
    • Vector Index
  • Transactions
  • Triggers
  • Query Management
  • Execution Plan
  • Backup and Restore
    • Variables
    • Values and Types
    • Comments
    • Reserved Words
    • Naming Conventions
    • Syntactic Notation
  • GQL Conformance
  1. Docs
  2. /
  3. ISO GQL

Query Management

Most GQL queries are executed as real-time operations: results are returned to the client once execution is complete and are not stored on the server. Some operations — such as algorithm write modes, imports, and exports — run as background tasks instead, returning a task_id and persisting their results on the server. The system tracks both, providing commands to list and cancel running queries and to monitor, stop, or delete tasks.

Showing Queries

Lists all currently running queries across all connections. This command is never blocked by concurrency limits.

GQL
SHOW QUERIES

-- Equivalent
TOP QUERIES

-- Shorthand
TOP

Returns a table with the following columns:

FieldDescription
query_idThe unique identifier of the query (e.g., q1, q2).
query_textThe query text, truncated to 100 characters.
start_timeThe time the query started executing.
duration_msHow long the query has been running, in milliseconds.
statusCurrent state of the query: running or canceling.

Killing Queries

Cancels a running query by its ID. The query transitions to canceling status and stops at the next cancellation checkpoint.

GQL
KILL QUERY 'q1'

Use SHOW QUERIES to find the query_id of the query you want to cancel.

Background Tasks

Certain operations run as background tasks, such as algorithm execution. Tasks are tracked by the server and can be monitored, stopped, or deleted.

Showing Tasks

List all tasks:

GQL
SHOW TASKS
FieldDescription
task_idUnique task identifier (e.g., task_550e8400-...).
typeTask type: algorithm, import, or export.
queryThe query or command that created the task.
statusCurrent status: pending, running, completed, failed, or cancelled.
started_atWhen the task started executing.
progressCompletion percentage (0–100).

Show a specific task:

GQL
SHOW TASK 'task_550e8400-e29b-41d4-a716-446655440000'

Stopping a Task

Cancel a running task:

GQL
STOP 'task_550e8400-e29b-41d4-a716-446655440000'

Deleting a Task

Remove a task from the registry and delete its result files:

GQL
DELETE TASK 'task_550e8400-e29b-41d4-a716-446655440000'

Query Defaults

SettingDefaultDescription
Query timeout30 seconds (driver)The query timeout is set by the client driver (default 30 seconds). If the client sends no timeout, the server falls back to its -default-timeout flag (default 5 minutes).
Read concurrency slots16Maximum concurrent read queries (e.g., MATCH, aggregations).
Write concurrency slots4Maximum concurrent write queries (e.g., INSERT, DELETE, SET).

When all slots are occupied, new queries block until a slot becomes available or the query context is cancelled. Management commands (SHOW QUERIES, KILL QUERY, EXPLAIN) bypass the concurrency limits and always respond immediately.