Skip to content

Multi-row CREATE followed by startNode/endNode reports a nonexistent graphid #2552

Description

@YGY-001

Environment

  • Apache AGE 1.8.0
  • PostgreSQL 18.6
  • Docker image: apache/age:release_PG18_1.8.0

Reproduction

Execute the following Cypher through the standard AGE
ag_catalog.cypher('graph_name', $$...$$) interface:

UNWIND [1, 2] AS x
CREATE (a)-[r:R]->(b)
WITH startNode(r) AS s
RETURN s

Expected

The query returns two start vertices.

Actual

ERROR: graphid 281474976710659 does not exist

The graphid is generated internally and is not present in the Cypher input.

Controls

The one-row form succeeds:

UNWIND [1] AS x
CREATE (a)-[r:R]->(b)
WITH startNode(r) AS s
RETURN s

Directly returning the created entities for two rows also succeeds:

UNWIND [1, 2] AS x
CREATE (a)-[r:R]->(b)
RETURN a, b, r

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions