Development with AWS Services
A filtered DynamoDB Query returns no items but includes a LastEvaluatedKey. What should the application do to retrieve any remaining matches?
Show the answer
Correct answerD. Continue using LastEvaluatedKey as ExclusiveStartKey
AWhy not this: Removing the filter changes the requested results rather than continuing the filtered query.
BWhy not this: Strong consistency controls data freshness, not continuation through query results.
CWhy not this: A page can be empty after filtering even when more items remain to be evaluated.
DWhy this is right: ExclusiveStartKey resumes evaluation after the last item evaluated in the previous page.
Query applies its filter after evaluating a page, so a page can contain no returned matches and still require pagination. An empty items list alone does not establish that the query is complete.