AGE lets a later `MERGE` feed a node into an earlier unrestricted `MATCH` scan
I maintainer di solito rispondono entro 3 giorni
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 45/100
Direzione di ricerca
Start by tracing how AGE plans and executes MATCH scans when later clauses such as DETACH DELETE and MERGE write to the same graph; the reproduction compares a direct query with one that materializes the earlier rows through collect and UNWIND. Find the relevant planner or executor code and tests for clause composition, then add coverage for both queries. Done means both return 2 rows on the reported environment.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Environment
- Apache AGE
1.8.0, PostgreSQL18.6 - Docker image:
apache/age:release_PG18_1.8.0
Reproduction
Create two initially unlabeled nodes in each of two clean graphs:
LOAD 'age';
SET search_path = ag_catalog, public;
SELECT ag_catalog.create_graph('age_repro24_left');
SELECT *
FROM ag_catalog.cypher('age_repro24_left', $$
CREATE (), ()
$$) AS (v agtype);
SELECT ag_catalog.create_graph('age_repro24_right');
SELECT *
FROM ag_catalog.cypher('age_repro24_right', $$
CREATE (), ()
$$) AS (v agtype);
Baseline — age_repro24_left
SELECT *
FROM ag_catalog.cypher('age_repro24_left', $$
MATCH (n)
DETACH DELETE n
MERGE (:New)
RETURN count(*) AS rows
$$) AS (rows agtype);
Row-materialized variant — age_repro24_right
SELECT *
FROM ag_catalog.cypher('age_repro24_right', $$
MATCH (n)
WITH {n: n} AS row
WITH collect(row) AS rows
UNWIND rows AS row
WITH row.n AS n
DETACH DELETE n
MERGE (:New)
RETURN count(*) AS rows
$$) AS (rows agtype);
The collect/UNWIND block preserves the two input rows and their bindings;
it materializes the earlier MATCH result before the later writes.
Expected and actual
The initial MATCH should bind the two nodes that exist when that clause is
evaluated. The later MERGE must not add another row to that already-completed
scan. Both queries should therefore return 2.
On AGE 1.8.0 / PostgreSQL 18.6:
baseline: 3 rows
barrier: 2 rows
The official Cypher clause-composition documentation states that a clause
cannot observe writes made by a later clause and notes that a MATCH before
CREATE does not find the node created later in the query: Neo4j Cypher
clause composition.
- Lingua principale
- C
- Stelle
- 4.9k
- Fork
- 535
- Merge medio
- 10g 13h
- PR unite (30g)
- 7
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di apache/age
-
Integer division by -1 on INT64_MIN raises a misclassified floating-point exception (22P01) instead of bigint out of rangeForse già presa @sean0407 l’ha presa 12 giorni fa. Apertabug
Difficoltà 2/5 1-3 ore Idoneità per principianti 74/100
I maintainer di solito rispondono entro 3 giorni
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 88/100
I maintainer di solito rispondono entro 3 giorni
-
bug
Difficoltà 4/5 3-5 giorni Idoneità per principianti 53/100
I maintainer di solito rispondono entro 3 giorni
-
bug
Difficoltà 4/5 3-5 giorni Idoneità per principianti 45/100
I maintainer di solito rispondono entro 3 giorni
-
bug
Difficoltà 4/5 3-5 giorni Idoneità per principianti 48/100
I maintainer di solito rispondono entro 3 giorni
Issue simili
-
开发板墙缺少 ESP32_S31_MOSAICOAperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 67/100
espressif/esp-vision#16 · 1 commento ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 74/100
libsdl-org/SDL#16577 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 66/100
I maintainer di solito rispondono entro 1 giorno
-
halt_error adds a trailing newline for non-string input, contrary to the manualForse già presa @Huang-404-Q l’ha presa oggi. Aperta
Difficoltà 1/5 1-3 ore Idoneità per principianti 88/100
I maintainer di solito rispondono entro 2 giorni
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
MerginMaps/geodiff#272 ·