# Filtered collections and metadata

**URL:** <https://discuss.emberjs.com/t/filtered-collections-and-metadata/6490>\
**Category:** Ember Data\
**Created:** [October 13, 2014, 4:38pm UTC](https://discuss.emberjs.com/t/filtered-collections-and-metadata/6490 "2014-10-13T16:38:01Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![xcambar](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.emberjs.com/xcambar/32/11309_2.png) [@xcambar](https://discuss.emberjs.com/u/xcambar)\
**Post date:** [October 13, 2014, 4:38pm UTC](https://discuss.emberjs.com/t/filtered-collections-and-metadata/6490/1 "2014-10-13T16:38:01Z")

</div>

Hey there, Probably a too simple question, but I can’t find any definitive argument on this:

When I’m fetching all my `Stuff` instances, the metadata contains a total of (say) `42`. Based on that and other metadata, paginating is pretty easy.

When I’m fetching all my `Stuff` where `{ name: "Bob"}` (17 results), what should be the value of `metadata.total` ? 42 or 17 ?

- If it’s 42, then how do I know how many elements are in my query, and so how can I paginate ?
- If it’s 17, then the metadata for the type `Stuff` is now wrong.

I’m pretty sure I got something wrong, but I couln’t wrap my mind around this particular issue…

Thank you all
