Skip to content
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

apoc.coll.min and max comparsion operator logic like cypher #1473

Merged
merged 1 commit into from Apr 8, 2020

Conversation

lqst
Copy link
Contributor

@lqst lqst commented Apr 2, 2020

Fixes #1463

One sentence summary of the change.

comparsion operator logic like cypher

A brief list of proposed changes in order to fix the issue:

  • apoc.coll.min and max doing a reduce db call
  • Added unit test for max date/datetime

Note 1: I ran some performance test with jmh and could not see any significant impact

Note 2: There is a ton of other places where we can discuss if apoc is implementing "cypher like" operator logic.

@jexp
Copy link
Member

jexp commented Apr 2, 2020

Thanks a lot. I’m only on mobile but guess lists with null were in the regular test

@lqst
Copy link
Contributor Author

lqst commented Apr 6, 2020

Yes I tested min and max with lists that contain null. The logic is treating null as if it is not a value (it neither smaller nor larger than any other value).

@mneedham mneedham merged commit a7b20f3 into neo4j-contrib:3.5 Apr 8, 2020
mneedham pushed a commit that referenced this pull request Apr 8, 2020
Co-authored-by: Håkan Löfqvist <hakan.lofqvist@neo4j.com>
mneedham pushed a commit that referenced this pull request Apr 9, 2020
Co-authored-by: Håkan Löfqvist <hakan.lofqvist@neo4j.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants