Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add deprecation for identifier characters #786

Merged
merged 5 commits into from
Nov 27, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ New features are added to the language continuously, and occasionally, some feat
This section lists all of the features that have been removed, deprecated, added, or extended in different Cypher versions.
Replacement syntax for deprecated and removed features are also indicated.


[[cypher-deprecations-additions-removals-5.15]]
== Neo4j 5.15

Expand All @@ -25,7 +24,6 @@ Replacement syntax for deprecated and removed features are also indicated.
|===
| Feature
| Details

a|
label:functionality[]
label:deprecated[]
Expand All @@ -39,6 +37,32 @@ To continue using it, escape the identifier by adding backticks around the ident
This applies to all unescaped identifiers in Cypher, such as label expressions, properties, variable names or parameters.
In the given example, the quoted identifier would be \`my�identifier`.

a|
label:functionality[]
label:deprecated[]
[source, cypher, role="noheader"]
----
RETURN 1 as my$Identifier
----
a|
The character with the Unicode representation \`\u0024` is deprecated for unescaped identifiers and will not be supported in the future. To continue using it, escape the identifier by adding backticks around the identifier.
This applies to all unescaped identifiers in Cypher, such as label expressions, properties, variable names or parameters. In the given example, the quoted identifier would be \`my$identifier`.

The following Unicode Characters are deprecated in identifiers:
'\u0000', '\u0001', '\u0002', '\u0003', '\u0004', '\u0005', '\u0006', '\u0007',
'\u0008', '\u000E', '\u000F', '\u0010', '\u0011', '\u0012', '\u0013', '\u0014',
'\u0015', '\u0016', '\u0017', '\u0018', '\u0019', '\u001A', '\u001B', '\u007F',
'\u0080', '\u0081', '\u0082', '\u0083', '\u0084', '\u0086', '\u0087', '\u0088',
'\u0089', '\u008A', '\u008B', '\u008C', '\u008D', '\u008E', '\u008F', '\u0090',
'\u0091', '\u0092', '\u0093', '\u0094', '\u0095', '\u0096', '\u0097', '\u0098',
'\u0099', '\u009A', '\u009B', '\u009C', '\u009D', '\u009E', '\u009F', '\u0024',
'\u00A2', '\u00A3', '\u00A4', '\u00A5', '\u00AD', '\u0600', '\u0601', '\u0602',
'\u0603', '\u0604', '\u0605', '\u061C', '\u06DD', '\u070F', '\u08E2', '\u180E',
'\u200B', '\u200C', '\u200D', '\u200E', '\u200F', '\u202A', '\u202B', '\u202C',
'\u202D', '\u202E', '\u2060', '\u2061', '\u2062', '\u2063', '\u2064', '\u2066',
'\u2067', '\u2068', '\u2069', '\u206A', '\u206B', '\u206C', '\u206D', '\u206E',
'\u206F', '\u2E2F', '\uFEFF', '\uFFF9', '\uFFFA', '\uFFFB'

|===

[[cypher-deprecations-additions-removals-5.14]]
Expand Down
5 changes: 5 additions & 0 deletions modules/ROOT/pages/syntax/naming.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,11 @@ Some techniques to mitigate this are:

====

[NOTE]
====
Several special characters have been deprecated and will require escaping in Neo4j 6.0, see xref::deprecations-additions-removals-compatibility.adoc#cypher-deprecations-additions-removals-5.15[here] for the comprehensive list of deprecated characters.
====

== Scoping and namespace rules

* Node labels, relationship types and property names may re-use names.
Expand Down