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

Support 'IN' operator #186

Open
jacobg opened this issue Sep 17, 2019 · 0 comments
Open

Support 'IN' operator #186

jacobg opened this issue Sep 17, 2019 · 0 comments

Comments

@jacobg
Copy link

jacobg commented Sep 17, 2019

It would be great to support IN operator, where the right hand side is a list of values. Since the Datastore client doesn't natively support that, this library would need to split into multiple queries, and then merge the results. In fact, the original App Engine Datastore clients do just that:
https://cloud.google.com/appengine/docs/standard/java/datastore/queries#filters
https://cloud.google.com/appengine/docs/standard/python/datastore/queryclass#Instance_Methods

As an aside, the Python ndb library also supports IN operator:
https://googleapis.dev/python/python-ndb/latest/query.html#
In code it calls it a DisjunctionNode:
https://github.com/googleapis/python-ndb/blob/master/google/cloud/ndb/query.py#L637-L650

This operator should work either on a scalar value field, or on a list value field.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants