# How to get a dynamic count when applying 2 filters to the same list?

**URL:** <https://community.glideapps.com/t/how-to-get-a-dynamic-count-when-applying-2-filters-to-the-same-list/22711>\
**Category:** Ask for Help\
**Created:** [February 13, 2021, 6:01am UTC](https://community.glideapps.com/t/how-to-get-a-dynamic-count-when-applying-2-filters-to-the-same-list/22711 "2021-02-13T06:01:54Z")\
**Posts on this page:** 1\
**Showing post:** 5

<div class="post-metadata">

**Author:** ![Darren\_Murphy](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/darren_murphy/32/47326_2.png) [@Darren\_Murphy](https://community.glideapps.com/u/Darren_Murphy)\
**Post date:** [January 22, 2022, 1:52pm UTC](https://community.glideapps.com/t/how-to-get-a-dynamic-count-when-applying-2-filters-to-the-same-list/22711/5 "2022-01-22T13:52:38Z")

</div>

hmm, that post is quite old. Although the technique I described there could still be used, these days I’d probably recommend a slightly different approach that avoids complex relations.

With multiple choice components acting as filters, I’d be more likely to use the following approach:

- Write each choice component to a user specific column
- Use a series of single value columns to apply each choice selection to all rows in the table to be filtered
- Build logic in that table using one or more if-then-else columns to apply the filtering choices to each row. The end goal with this would be to have a single boolean column that indicates whether or not each row should be filtered. (`true` = filtered, `empty/false` = not filtered)
- Use the entire table in a single inline list component, filtering where the above column is not true
- And to get a dynamic count of filtered records, just do a rollup on the entire table, counting where that if-then-else column is not true.

The only really tricky part with the above is the if-then-else logic. The approach with this will vary from use case to use case, and can get quite hairy as the number of filters increases. But I’ve yet to encounter a situation where it can’t be done 😉

For an alternative approach that still uses dynamic relations, you can refer to [this method](https://community.glideapps.com/t/multi-filters-using-relations-a-new-way/36092) by @gvalero

---

_[View the full topic](https://community.glideapps.com/t/how-to-get-a-dynamic-count-when-applying-2-filters-to-the-same-list/22711)._
