You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
As in the title - invalid mutation query for one-to-many relations: auto-generated add* and delete* mutations generate invalid Cypher query.
MATCH (from:Item)
WHEREid(from) =toInteger($id)
MATCH (to:Category)
WHEREid(to) in $belongsTo// <---- hereMERGE (from)-[:BelongsTo]->(to)
WITHDISTINCTfromASaddItemBelongsToRETURNaddItemBelongsTo{_id:id(addItemBelongsTo)}ASaddItemBelongsTo
Generated cypher query
MATCH (from:Item)
WHEREid(from) =toInteger($id)
MATCH (to:Category)
WHEREid(to) =toInteger($belongsTo) // <---- invalid, $belongsTo is a list, not just a single integerMERGE (from)-[:BelongsTo]->(to)
WITHDISTINCTfromASaddItemBelongsToRETURNaddItemBelongsTo{_id:id(addItemBelongsTo)}ASaddItemBelongsTo
Additional context neo4j-graphql-java version: 1.7.0 (also tested 1.6.0 and 1.5.0 - the same issue)
The text was updated successfully, but these errors were encountered:
Describe the bug
As in the title - invalid mutation query for one-to-many relations: auto-generated add* and delete* mutations generate invalid Cypher query.
Test Case
GraphQL schema
GraphQL request
Expected cypher query
Generated cypher query
Additional context
neo4j-graphql-java
version: 1.7.0 (also tested 1.6.0 and 1.5.0 - the same issue)The text was updated successfully, but these errors were encountered: