Visitar URL original
Cypher MATCH on a time-series type silently returns no rows (SQL sees the samples), while the docs list Cypher as a time-series query language · Issue #10440 · ArcadeData/arcadedb · GitHub
Skip to content

Cypher MATCH on a time-series type silently returns no rows (SQL sees the samples), while the docs list Cypher as a time-series query language #10440

Closed

Description

@robfrank

A Cypher MATCH on a time-series type matches nothing. With two samples in a TIMESERIES type Ev, SQL SELECT count(*) FROM Ev returns 2, while Cypher MATCH (e:Ev) RETURN count(e) returns 0 and MATCH (e:Ev) RETURN e returns no rows. Nothing warns that the label belongs to a type Cypher cannot scan, so a query over time-series data just reports that there is none.

The time-series concepts page lists Cypher among the query languages for time-series data: "SQL, PromQL, Cypher, Gremlin, GraphQL, MongoDB QL" (timeseries.adoc L1424-L1425). I only tested Cypher, not Gremlin, GraphQL or MongoDB QL.

I found this while writing the Cypher version of a velocity check, which counts events per account per minute, for a blog post. It now buckets edge timestamps instead and says that Cypher does not read time-series types.

Repro

Server: arcadedata/arcadedb:latest, version 26.11.1-SNAPSHOT (build b91b5fd0), started with -Darcadedb.server.defaultDatabases=test[root]. Each statement below is one POST /api/v1/command/test request with the given language.

sqlscript: CREATE TIMESERIES TYPE Ev TIMESTAMP ts PRECISION MILLISECOND TAGS (k STRING) FIELDS (v DOUBLE);
           INSERT INTO Ev SET ts = 1792396800000, k = 'a', v = 1.0;
           INSERT INTO Ev SET ts = 1792396860000, k = 'a', v = 2.0;
sql:    SELECT count(*) AS n FROM Ev
  -> [{"n":2}]
cypher: MATCH (e:Ev) RETURN count(e) AS n
  -> [{"n":0}]
cypher: MATCH (e:Ev) RETURN e LIMIT 1
  -> []

Expected

One of these:

  • Cypher scans a time-series type the way SQL FROM does (an aggregation over it shows AGGREGATE FROM TIMESERIES in EXPLAIN), so MATCH (e:Ev) returns the samples as nodes with their timestamp, tags and fields.
  • MATCH on a time-series label fails with an error saying that Cypher does not query time-series types, and the docs table is corrected (I can do the docs side).

Silently returning zero rows is the worst of the options, because it looks like a correct answer.

Activity

  1. added this to the 26.11.1 milestone on Oct 20, 2026
  2. self-assigned this
    on Oct 20, 2026
  3. added a commit that references this issue on Oct 20, 2026
  4. robfrank commented on Oct 20, 2026

    @robfrank
    CollaboratorAuthor

    Fixed in #10443, using the second option in the issue. A Cypher pattern whose node label or relationship type names a TIMESERIES type used to return zero rows silently while SQL returned the samples. It now fails with an error that names the type and points you to SQL or PromQL. Note that queries which used to return nothing now fail instead.

    Still open:


    ❤️ Thanks for helping make ArcadeDB better! ArcadeDB is free and open source, sustained by its community. If it's useful to you or your company, please consider becoming a sponsor to keep development going.

  5. removed
    in progressThe team is actively working on this issue
    on Oct 20, 2026
  6. added a commit that references this issue on Nov 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

bugopencypherseverity:minorCosmetic, documentation, edge case, or a workaround existstimeseriesTime series module

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions