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

Queries/scans may return no data #75

Open
gabmontes opened this issue Sep 21, 2020 · 1 comment
Open

Queries/scans may return no data #75

gabmontes opened this issue Sep 21, 2020 · 1 comment

Comments

@gabmontes
Copy link

gabmontes commented Sep 21, 2020

Having a large data set and executing a filtered query may result in no documents at all when calling .find().exec(). Calling .find().raw().exec() instead properly shows there are more pages.

Since find().exec() just silently returns no records, callers unaware of the paging nature of the underlying scan process by AWS may think there are really no documents but this is incorrect. Just the first page has no documents.

A solution would be to let find().exec() fail if there are more pages (LastEvaluatedKey exists) so the caller knows the results are partial.

@gabmontes gabmontes changed the title Queries/scans have missing records Queries/scans may return no data Sep 22, 2020
@SamVerschueren
Copy link
Owner

Just throwing might be dangerous as well, although I understand the problem. Or would you only throw if the result set is empty but we do have a LastEvaluatedKey?

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

No branches or pull requests

2 participants