Repository navigation
FalkorDB v6.2.1
Highlights
FalkorDB 6.2.1 fixes the query-planning slowdowns that 6.2.0 listed as a known issue, and makes id() comparisons return the right rows for any value.
- Faster ingest with
UNWIND. AMATCHafterUNWINDagain finds its node through an index or by id for each row, instead of scanning a whole label or the whole graph. - Faster correlated joins. A join in a later
MATCH,OPTIONAL MATCH,WITHorCALL {}runs as a hash join again. - Correct
id()filters. Negative, fractional, null and non-numeric values in anid()comparison no longer return wrong rows or fail.
6.2.1 is a drop-in replacement for 6.2.0, with the same servers and RDB format. See Upgrade notes.
What's Changed
Performance
All three were regressions in 6.2.0. They came from planning consecutive MATCH clauses separately (#2981), which fixed wrong results but lost these plans.
- A
MATCHon an indexed property afterUNWINDseeks the index for each row again, instead of joining against a scan of the whole label. ForUNWIND $rows AS e MATCH (s:Sensor {id: e.sid}) MATCH (p:Reading {ts: e.pts})with 1M:Readingnodes, a 300-row batch went from 56.3 ms to 6.5 ms, and a single row from 54.0 ms to 0.1 ms. Large batches still use the join, so bulk loads stay as fast as in 6.2.0 (#3889, fixes #3887). - The same for
id():UNWIND $rows AS e MATCH (a) WHERE id(a) = e.s MATCH (b) WHERE id(b) = e.d CREATE (a)-[:R]->(b)looks up both nodes by id instead of scanning every node, or every node of the label. On a 200k-node graph, a one-row batch went from 8.7 ms to 0.24 ms (#3963, fixes #3965). - A join inside a later
MATCH,OPTIONAL MATCH,WITH … MATCHorCALL { WITH … }is planned as a hash join again, instead of comparing every pair of rows for each outer row. A benchmark query of the formMATCH (m:M {id: 0}) CALL { WITH m MATCH (a:A), (b:B) WHERE a.x = b.id RETURN count(*) AS c } RETURN cwent from 0.41 ms to 0.09 ms (#3930, fixes #3962).
Bug fixes
- An
id()comparison that the planner turns into an id lookup now returns the same rows as the comparison itself (#3017, fixes #3008, #2266, #2648):- A negative value no longer wraps around.
id(n) > -1returned no rows, andid(n) <= -1returned every node. id(n) = null,id(n) = '1',id(n) = 1.0andid(n) > 1.5no longer fail withNode ID must be an integer. A null or non-numeric value matches no node. A float compares as a number, soid(n) = 1.0matches node 1 andid(n) > 1.5starts at node 2.
- A negative value no longer wraps around.
Known issues
These are open in 6.2.1. Fixes for most are in review.
| Issue | What happens | Workaround |
|---|---|---|
| #3375 | With two or more grouping keys, an aggregate can return another aggregate's value, e.g. RETURN n.country, n.city, count(n), sum(n.age) gives the count as the sum. avg() in the same shape crashes the server. |
Project the keys and values with WITH first: WITH n.country AS country, n.city AS city, n.age AS age RETURN country, city, count(*), avg(age). |
| #3282 | CREATE p=(...) as the last clause after another clause fails with Variable not found and creates nothing. |
End the query with a RETURN, e.g. RETURN count(p). |
| #3376 | A range index on a relationship property can make traversals from bound nodes much slower (5 ms to 5.4 s in the report). | Drop the relationship index if those traversals matter more than the indexed lookups. |
| #2782 | Using the same graph name in two logical databases (or MOVE/SWAPDB onto one) leaves the first graph rejecting every write. |
Keep graph names unique across databases. |
| #3309 | Diskless replica loading (repl-diskless-load) is not supported. Replicas save the primary's RDB to disk before loading it. |
None needed: replication works, through disk. |
| #3546 | A full-text index's language option is not applied to stemming; documents are stemmed as English. |
None yet. |
| #2540 | CALL db.idx.fulltext.createNodeIndex(...) fails. |
Use CREATE FULLTEXT INDEX FOR (n:Label) ON (n.prop). |
| #2603 | =~ matches a substring instead of the whole string. |
Anchor the pattern: '^...$'. |
Upgrade notes
- From 6.2.0. Pull the new image; no data step is needed. 6.2.1 ships the same servers (Valkey 9.2.0 by default, Redis 8.10.2 on
-redistags) and the same RDB encoding version (20). Docker tags follow the 6.2.0 table, with6.2.1in place of6.2.0. - From 6.0.x or 4.22. Follow the 6.2.0 upgrade notes:
latestnow runs Valkey, and a volume written by Redis needs a migration step first. - Behavior change. An
id()comparison with a float, null or string no longer fails (see Bug fixes). A float now matches as a number:WHERE id(n) = 1.0returns node 1, where 4.22 (the C engine) returns no rows for any float (#3017).