-
Notifications
You must be signed in to change notification settings - Fork 157
Closed
Description
Hi to all,
I am using the ANTLR4 grammar in version M16 (https://s3.amazonaws.com/artifacts.opencypher.org/M16/Cypher.g4) and have an issue with oC_MultiPartQuery:
In the grammar, it says:
oC_MultiPartQuery
: ( ( oC_ReadingClause SP? )* ( oC_UpdatingClause SP? )* oC_With SP? )+ oC_SinglePartQuery ;To my understanding, it is therefore possible to write something like this
MATCH (c:Label), (d:Label2) SET c.property = d.property WITH c MATCH (e:Label3 {name: c.name}) RETURN cHowever, in the ANTLR4 parser (Java), i only get List<oC_ReadingClause>, List<oC_UpdatingClause> and List<oC_With>. Therefore, I cannot distinguish whether (e:Label3 {name: c.name}) belongs before which entry in List<oC_With> or after any entry.
Therfore, I propose changing the grammar to something like
oC_MultiPartQuery
: ( oC_MultiPartQueryGroup )+ oC_SinglePartQuery ;
oC_MultiPartQueryGroup
: ( oC_ReadingClause SP? )* ( oC_UpdatingClause SP? )* oC_With SP? ;I am no expert in grammars so please excuse me if I missed something here.
All the best,
Daniel
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels