-
Notifications
You must be signed in to change notification settings - Fork 6
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
Include variable scope clause in deprecated Cypher query #6
Conversation
86bee58
to
502485b
Compare
502485b
to
2a01b8f
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
@@ -93,7 +93,7 @@ def _get_search_index_query( | |||
"YIELD node, score " | |||
), | |||
SearchType.HYBRID: ( | |||
"CALL { " | |||
"CALL () { " |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are we supporting only neo4j >= 5.23 ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good point, I should include the old queries for older versions
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I created another ticket to add support for Neo4j < 5.23 across the package. Feel free to add in support here but ideally we should think about exactly which versions we want to support and come up with a strategy that works across the package.
Summary
The previous Cypher query would include a warning that the Cypher query will be deprecated. This PR update the query to have a variable scope clause. See https://neo4j.com/docs/cypher-manual/current/subqueries/call-subquery/#variable-scope-clause
This PR also adds a unit test and was manually tested.