Skip to content

Commit

Permalink
Disallow unquoted database names with dot (#1948)
Browse files Browse the repository at this point in the history
Document what changed here:
neo-technology/neo4j#27074

---------

Co-authored-by: Reneta Popova <[email protected]>
  • Loading branch information
l-heemann and renetapopova authored Dec 11, 2024
1 parent a9482b6 commit 47d8bb4
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@ Support for database names starting with a numeric character is available from N
The `-` (dash) and `.` (dot) characters are not legal in Cypher variables.
Names containing a `-` or that begin with a numeric character must be enclosed within backticks.
For example, `CREATE DATABASE ++`main-db`++` is a valid database name.
Database names are the only identifier for which dots do not need to be quoted.
For example `main.db` is a valid database name.
However, this behavior is deprecated due to the difficulty of determining if a dot is part of the database name or a delimiter for a database alias in a composite database.
In Cypher 25, names that contain a dot (`.`) must be quoted in backticks.
However, using dots in database names is not recommended, as it makes it difficult to determine if a dot is part of the database name or a delimiter for a database alias in a composite database.
A future version of Neo4j may entirely disallow database names with dots.
====

It is possible to create an alias to refer to an existing database to avoid these restrictions.
Expand Down

0 comments on commit 47d8bb4

Please sign in to comment.