GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — `COLLECT { ... }` subqueries may return `null` instead of the collected list. · Issue #3957 · ArcadeData/arcadedb

COLLECT { ... } subqueries may return null instead of the collected list. #3957

New issue
Copy link
New issue
Copy link
Closed
Bug
Closed
COLLECT { ... } subqueries may return null instead of the collected list.#3957
Bug
Copy link
Assignees
lvca
Labels
opencypher
Milestone
26.4.2

Description

@Silence6666668
Silence6666668
opened on Apr 22, 2026
Issue body actions

ArcadeDB version

Observed on Docker images:

  • arcadedata/arcadedb:latest
  • arcadedata/arcadedb:26.4.1-SNAPSHOT

Environment

  • Docker on Windows host
  • ArcadeDB queried through the HTTP API: /api/v1/command/arcade
  • Requests sent in the same shape used by ArcadeDB Studio:
    • language: opencypher
    • serializer: studio

Describe the bug

COLLECT { ... } subqueries may return null instead of the collected list.

In the minimized repro below, Alice knows Bob, while Bob and Charlie know nobody.

Neo4j returns:

Alice   ["Bob"]
Bob     []
Charlie []

ArcadeDB returns null for every row instead of a list, including the row where one matching value clearly exists.

To Reproduce

Setup

CREATE (:Person {name:'Alice'}),
       (:Person {name:'Bob'}),
       (:Person {name:'Charlie'});

MATCH (a:Person {name:'Alice'}), (b:Person {name:'Bob'})
CREATE (a)-[:KNOWS]->(b);

Query

MATCH (p:Person)
RETURN p.name AS person,
       COLLECT { MATCH (p)-[:KNOWS]->(f:Person) RETURN f.name } AS friendNames
ORDER BY person;

Expected behavior

The correlated collect subquery should produce a list for each outer row:

Alice   ["Bob"]
Bob     []
Charlie []

Actual behavior

ArcadeDB returns:

Alice   null
Bob     null
Charlie null

Control cases

Control 1, the equivalent query written with OPTIONAL MATCH and ordinary collect() behaves correctly on both Neo4j and ArcadeDB:

MATCH (p:Person)
OPTIONAL MATCH (p)-[:KNOWS]->(f:Person)
RETURN p.name AS person, collect(f.name) AS friendNames
ORDER BY person;

Observed result:

Alice   ["Bob"]
Bob     []
Charlie []

Control 2, a correlated EXISTS { ... } subquery also behaves correctly on both engines:

MATCH (p:Person)
RETURN p.name AS person,
       EXISTS { MATCH (p)-[:KNOWS]->(:Person) } AS hasFriend
ORDER BY person;

Observed result:

Alice   true
Bob     false
Charlie false

This suggests the issue is specifically tied to COLLECT { ... } subqueries, not to correlated subqueries in general.

Activity

  1. lvca
    self-assigned this
    on Apr 22, 2026
  2. lvca
    added the
    Bug
    issue type on Apr 22, 2026
  3. lvca
    added this to the 26.4.1 milestone on Apr 22, 2026
  4. lvca
    added a commit that references this issue on Apr 22, 2026

    fix: COLLECT { ... } subqueries were returning null instead of the co…

    43869fb
  5. lvca commented on Apr 22, 2026

    @lvca
    lvca
    on Apr 22, 2026
    Member
    More actions

    Thanks for the detailed report! Fixed now.

    Reacted by Silence6666668
  6. lvca
    closed this as completedon Apr 22, 2026
  7. mergify
    added a commit that references this issue on May 3, 2026

    chore(deps): bump org.postgresql:postgresql from 42.7.10 to 42.7.11 […

    03c204f
  8. robfrank
    added
    opencypher
    on May 10, 2026
  9. robfrank
    added a commit that references this issue on May 12, 2026

    fix: COLLECT { ... } subqueries were returning null instead of the co…

    bd424c7
  10. tae898
    added 2 commits that reference this issue on Jun 28, 2026

    fix: COLLECT { ... } subqueries were returning null instead of the co…

    9f7f7af

    chore(deps): bump org.postgresql:postgresql from 42.7.10 to 42.7.11 […

    8a485d0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

  • @lvca
    lvca

Labels

opencypher

Type

Bug

Projects

No projects

    Milestone

    • 26.4.2

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

    You are visitor 01402775 — GeezerVison does not store the pages you look up.
    Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.