Skip to content

Conversation

@hschimpf
Copy link
Contributor

@hschimpf hschimpf commented Apr 12, 2024

Allow to get a model's count.

DynamoDB allows to specify which attributes will be returned in the query. But also has the special value COUNT to get only the count of items.

The used read capacity units is the same as fetching the items, but the payload isn't. In some cases is useful to fetch only the count of items in order to reduce the bandwidth used. It's also useful to bypass the 1MB limit of responses

Copy link

@Equinox766 Equinox766 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It works

@kitar
Copy link
Owner

kitar commented Jun 9, 2025

Thank you for this excellent PR (and #48)! Your implementation is truly impressive.
Due to compatibility issues with older PHP versions, I’ve cherry-picked this into the v2.x-dev branch.

@kitar kitar closed this Jun 9, 2025
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.

3 participants