Skip to content

Commit 3dca039

Browse files
Merge branch 'dev' into cypher_version_ops_manual
2 parents 3abda42 + 3d3070d commit 3dca039

File tree

4 files changed

+115
-4
lines changed

4 files changed

+115
-4
lines changed

antora.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,4 @@ nav:
77
- modules/ROOT/content-nav.adoc
88
asciidoc:
99
attributes:
10-
neo4j-version: '2025.06'
10+
neo4j-version: '2025.07'

modules/ROOT/pages/deprecations-additions-removals-compatibility.adoc

Lines changed: 106 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -341,6 +341,112 @@ a|
341341
label:functionality[]
342342
label:new[]
343343

344+
[source, cypher, role="noheader"]
345+
----
346+
CREATE [COMPOSITE] DATABASE actors SET DEFAULT LANGUAGE CYPHER 25
347+
----
348+
349+
a| Set the default Cypher version for a standard or composite database when creating it.
350+
The available versions are `CYPHER 25` and `CYPHER 5`.
351+
If not specified, the default language for the database is set to the default language of the DBMS.
352+
For more information, see the following sections in the Operations Manual:
353+
354+
* link:{neo4j-docs-base-uri}/operations-manual/current/database-administration/standard-databases/create-databases/#_set_a_default_cypher_version_for_a_standard_database[Set a default Cypher version for a standard database].
355+
* link:{neo4j-docs-base-uri}/operations-manual/current/database-administration/composite-databases/create-composite-databases/#composite-databases-default-language[Set the default Cypher version for a composite database].
356+
357+
a|
358+
label:functionality[]
359+
label:new[]
360+
361+
[source, cypher, role="noheader"]
362+
----
363+
CREATE ALIAS `remote-with-default-language`
364+
FOR DATABASE `northwind-graph-2020`
365+
AT "neo4j+s://location:7687"
366+
USER alice
367+
PASSWORD 'example_secret'
368+
DEFAULT LANGUAGE CYPHER 25
369+
----
370+
371+
a| Set the default Cypher version for a remote database alias when creating it.
372+
The available versions are `CYPHER 5` and `CYPHER 25`.
373+
Local database aliases and database aliases in composite databases cannot be assigned a default Cypher version.
374+
Local database aliases always have the Cypher version of their target database and database aliases in composite databases always have the Cypher version of the composite database they belong to.
375+
For more information, see the link:{neo4j-docs-base-uri}/operations-manual/current/database-administration/aliases/manage-aliases-standard-databases/#_set_a_default_cypher_version_for_remote_database_aliases[Operations Manual -> Set a default Cypher version for remote database aliases].
376+
377+
a|
378+
label:functionality[]
379+
label:new[]
380+
[source, cypher, role="noheader"]
381+
----
382+
ALTER DATABASE movies SET DEFAULT LANGUAGE CYPHER 25
383+
----
384+
385+
a| Alter the default Cypher version of an existing standard or composite database.
386+
The available versions are `CYPHER 25` and `CYPHER 5`.
387+
For more information, see the link:{neo4j-docs-base-uri}/operations-manual/current/database-administration/standard-databases/alter-databases/#alter-database-default-language[Operations Manual -> Alter the default Cypher version of an existing database].
388+
389+
a|
390+
label:functionality[]
391+
label:new[]
392+
393+
[source, cypher, role="noheader"]
394+
----
395+
ALTER ALIAS `remote-with-default-language` SET DATABASE DEFAULT LANGUAGE CYPHER 25
396+
----
397+
398+
a| Alter the default Cypher version of a remote database alias.
399+
The available versions are `CYPHER 25` and `CYPHER 5`.
400+
It is not possible to alter the default Cypher version of a local database alias or an alias belonging to a composite database.
401+
Local database aliases always have the Cypher version of their target database and aliases belonging to composite databases always have the Cypher version of the composite database.
402+
For more information, see the link:{neo4j-docs-base-uri}/operations-manual/current/database-administration/aliases/manage-aliases-standard-databases/#alter-default-language-remote-database-alias[Operations Manual -> Alter the default Cypher version of a remote database alias].
403+
404+
a|
405+
label:functionality[]
406+
label:new[]
407+
408+
[source, cypher, role="noheader"]
409+
----
410+
SHOW DATABASES YIELD name, defaultLanguage
411+
----
412+
413+
a| The new return column `defaultLanguage` for the `SHOW DATABASE` command returns the default language of a database.
414+
This column is not returned by default; it can only be returned using `YIELD`.
415+
For more information, see the link:{neo4j-docs-base-uri}/operations-manual/current/database-administration/standard-databases/listing-databases/#_show_the_default_cypher_version_of_a_database[Operations Manual -> Show the default Cypher version of a database].
416+
417+
a|
418+
label:functionality[]
419+
label:new[]
420+
421+
[source, cypher, role="noheader"]
422+
----
423+
SHOW ALIAS `remote-with-default-language` FOR DATABASE YIELD name, defaultLanguage
424+
----
425+
426+
a| The new return column `defaultLanguage` for the `SHOW ALIAS` command returns the default language of a database alias.
427+
This column is not returned by default; it can only be returned using `YIELD`.
428+
For more information, see the link:{neo4j-docs-base-uri}/operations-manual/current/database-administration/aliases/manage-aliases-standard-databases/#manage-aliases-list[Operations Manual -> List database aliases].
429+
430+
a|
431+
label:functionality[]
432+
label:new[]
433+
434+
[source, cypher, role="noheader"]
435+
----
436+
CYPHER 25
437+
MATCH (n:Person)
438+
FILTER n.age < 35
439+
RETURN n.name AS name
440+
----
441+
442+
a| New query option: `CYPHER 25`.
443+
Prepending a query with `CYPHER 25` ensures that a query is run with Cypher 25, regardless of the default language of a database.
444+
(The ability to select `CYPHER 5` was introduced in Neo4j 5.21).
445+
446+
a|
447+
label:functionality[]
448+
label:new[]
449+
344450
[source, cypher, role="noheader"]
345451
----
346452
RETURN 1 AS a

modules/ROOT/pages/queries/index.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ It also explains how to select the version of Cypher in which queries are run, a
66

77
* xref:queries/concepts.adoc[]
88
* xref:queries/basic.adoc[]
9-
* xref:queries/select-version.adoc[]
9+
* xref:queries/select-version.adoc[] label:new[Introduced in Neo4j 2025.06]
1010
* xref:queries/composed-queries/index.adoc[]
1111
** xref:queries/composed-queries/combined-queries.adoc[]
1212
** xref:queries/composed-queries/conditional-queries.adoc[] label:new[Introduced in Neo4j 2025.06]

modules/ROOT/pages/queries/select-version.adoc

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
:description: Information about how to select Cypher version for queries or databases.
2+
:page-role: new-2025.06
23

34
= Select Cypher version
45

@@ -89,32 +90,36 @@ It is, therefore, recommended to set the default language to Cypher 25 and migra
8990
======
9091

9192
.Cypher 25 query on a Neo4j 2025.06+ database with Cypher 5 as default language
93+
// tag::queries_select_version_cypher_25[]
9294
[source,cypher]
9395
----
9496
CYPHER 25
9597
MATCH (n:Order)-[r:SHIPPED_TO]->(:Address)
9698
SET n = properties(r)
9799
----
100+
// end::queries_select_version_cypher_25[]
98101

99102
======
100103
101104
[.include-with-Cypher-5]
102105
======
103106

104107
.Cypher 5 query on a Neo4j 2025.06+ database with Cypher 25 as default language
108+
// tag::queries_select_version_cypher_5[]
105109
[source,cypher]
106110
----
107111
CYPHER 5
108112
MATCH (n:Order)-[r:SHIPPED_TO]->(:Address)
109113
SET n = r
110114
----
115+
// end::queries_select_version_cypher_5[]
111116

112117
======
113118
=====
114119

115-
Selecting `CYPHER 25` ensures that the query will be executed using the language as it exists in the version of Neo4j that the database is currently running, provided it is on Neo4j 2025.06 or later.
120+
Selecting `CYPHER 25` ensures that the query will be executed using Cypher 25 as it exists in the version of Neo4j that the database is currently running, provided it is on Neo4j 2025.06 or later.
116121

117-
Selecting `CYPHER 5` ensures that the query will be executed using the language as it existed at the time of the Neo4j 2025.06 release.
122+
Selecting `CYPHER 5` ensures that the query will be executed using Cypher 5 as it existed at the time of the Neo4j 2025.06 release.
118123
Any changes introduced after the 2025.06 release will not affect the query.
119124

120125
[[procedures-and-functions]]

0 commit comments

Comments
 (0)