Skip to content

Commit 0e457d6

Browse files
neo4j-browser-botgithub-actions[bot]anderson4j
authored
Automated update of artifacts to neo4j version 2026.03.0 (#657)
Co-authored-by: Dev Artifact Bot <github-actions[bot]@users.noreply.github.com> Co-authored-by: Isak <isak.nilsson@neo4j.com>
1 parent b0170f9 commit 0e457d6

6 files changed

Lines changed: 13057 additions & 13026 deletions

File tree

.changeset/four-dots-double.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
---
2+
"@neo4j-cypher/language-support": patch
3+
"@neo4j-cypher/lint-worker": patch
4+
---
5+
6+
Updates grammar and semantic analysis to 2026.03

packages/language-support/src/antlr-grammar/Cypher25Parser.g4

Lines changed: 19 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -113,6 +113,7 @@ clause
113113
| loadCSVClause
114114
| foreachClause
115115
| orderBySkipLimitClause
116+
| composableCommandClauses
116117
;
117118

118119
useClause
@@ -937,8 +938,7 @@ command
937938
| stopDatabase
938939
| enableServerCommand
939940
| allocationCommand
940-
| showCommand
941-
| terminateCommand
941+
| showAdminCommand
942942
)
943943
;
944944

@@ -980,23 +980,16 @@ dropCommand
980980
)
981981
;
982982

983-
showCommand
983+
showAdminCommand
984984
: SHOW (
985985
showAliases
986-
| showConstraintCommand
987-
| showCurrentGraphTypeCommand
988986
| showCurrentUser
989987
| showDatabase
990-
| showFunctions
991-
| showIndexCommand
992988
| showPrivileges
993-
| showProcedures
994989
| showRolePrivileges
995990
| showRoles
996991
| showServers
997-
| showSettings
998992
| showSupportedPrivileges
999-
| showTransactions
1000993
| showUserPrivileges
1001994
| showUsers
1002995
| showAuthRules
@@ -1008,6 +1001,11 @@ showCommandYield
10081001
| whereClause
10091002
;
10101003

1004+
showCommandYieldWhere
1005+
: yieldClause
1006+
| whereClause
1007+
;
1008+
10111009
yieldItem
10121010
: variable (AS variable)?
10131011
;
@@ -1066,7 +1064,7 @@ showIndexType
10661064
;
10671065

10681066
showIndexesEnd
1069-
: indexToken showCommandYield? composableCommandClauses?
1067+
: indexToken showCommandYieldWhere?
10701068
;
10711069

10721070
showConstraintCommand
@@ -1090,19 +1088,19 @@ constraintExistType
10901088
;
10911089

10921090
showConstraintsEnd
1093-
: constraintToken showCommandYield? composableCommandClauses?
1091+
: constraintToken showCommandYieldWhere?
10941092
;
10951093

10961094
showCurrentGraphTypeCommand
1097-
: CURRENT GRAPH TYPE showCommandYield? composableCommandClauses?
1095+
: CURRENT GRAPH TYPE showCommandYieldWhere?
10981096
;
10991097

11001098
showProcedures
1101-
: (PROCEDURE | PROCEDURES) executableBy? showCommandYield? composableCommandClauses?
1099+
: (PROCEDURE | PROCEDURES) executableBy? showCommandYieldWhere?
11021100
;
11031101

11041102
showFunctions
1105-
: showFunctionsType? functionToken executableBy? showCommandYield? composableCommandClauses?
1103+
: showFunctionsType? functionToken executableBy? showCommandYieldWhere?
11061104
;
11071105

11081106
functionToken
@@ -1124,7 +1122,7 @@ showTransactions
11241122
;
11251123

11261124
terminateTransactions
1127-
: transactionToken stringsOrExpression showCommandYield? composableCommandClauses?
1125+
: transactionToken stringsOrExpression showCommandYieldWhere?
11281126
;
11291127

11301128
showSettings
@@ -1135,8 +1133,12 @@ settingToken
11351133
: SETTING | SETTINGS
11361134
;
11371135

1136+
// Keeping both sides here as optional instead of having one mandatory and then optionally call `namesAndClauses`,
1137+
// to not prioritize stringsOrExpression over regular clauses (for example, we don't want `SHOW SETTINGS WITH * MATCH (*)`
1138+
// to be parsed as variable `WITH` multiplied with the function call `MATCH (*)`)
11381139
namesAndClauses
1139-
: (showCommandYield? | stringsOrExpression showCommandYield?) composableCommandClauses?
1140+
: showCommandYieldWhere?
1141+
| stringsOrExpression showCommandYieldWhere?
11401142
;
11411143

11421144
stringsOrExpression

0 commit comments

Comments
 (0)