-
Notifications
You must be signed in to change notification settings - Fork 29
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
Occurance count() vs search()['count'] #75
Comments
I think count and search work slightly differently. count only allows one value per query while search allows more than 1. I can document that better. for count i guess a list comprehension or similar would work |
great! that helps!
sure, but is there any reason to prefer the count api over search()['count'] then? |
At one point a few years back they said they would deprecate the occurrence/count route https://dev.gbif.org/issues/browse/POR-3173/ but it is still around. there may be a time penalty for using search instead of count, I don't know. search seems better since you can do multiple dataset keys |
Right. Thanks a lot. I guess this can be addressed with updated docs. I can review a PR of that helps. |
- add checker in occurrences.count that values are at most length 1 - add test for this checker - add docs for occurrences.count saying values length 1 only, point to search for more than 1 - bump version
I get an explainable behavior when I'm calling the
occurances.count()
using a list ofdataKey
.the result seems to be as expected. Is this a bug or is there any other reason for the different behaviors?
The text was updated successfully, but these errors were encountered: