# Filtering views on fields being equal

**URL:** <https://forums.knack.com/t/filtering-views-on-fields-being-equal/7798>\
**Category:** API & Custom Code\
**Created:** [November 6, 2015, 6:40am UTC](https://forums.knack.com/t/filtering-views-on-fields-being-equal/7798 "2015-11-06T06:40:40Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![JasonCocke86858](https://avatars.discourse-cdn.com/v4/letter/j/d9b06d/32.png) [@JasonCocke86858](https://forums.knack.com/u/JasonCocke86858)\
**Post date:** [November 6, 2015, 6:40am UTC](https://forums.knack.com/t/filtering-views-on-fields-being-equal/7798/1 "2015-11-06T06:40:40Z")

</div>

Has anyone successfully written code allowing the filtering of a view say a table or list by the contents of a field from a connected object and the logged in user?

For example:

Filter by the logged in user and the following:  
  
object\_55, field\_1260 = object\_6, field\_1256

Knack doesn't appear to have this as part of its builder functionality and its a core need for my application. I dabble with code but that is all, so anyone who has tried this successfully or thinks they know how to do it I'd be very grateful for any input.

---

<div class="post-metadata">

**Author:** ![LaraSchoen37547](https://avatars.discourse-cdn.com/v4/letter/l/5f9b8f/32.png) [@LaraSchoen37547](https://forums.knack.com/u/LaraSchoen37547)\
**Post date:** [June 24, 2016, 7:58am UTC](https://forums.knack.com/t/filtering-views-on-fields-being-equal/7798/2 "2016-06-24T07:58:47Z")

</div>

I really need this too. I have an equation that calculates a value. I then want to filter a child table using the value from the equation. Anyone found a work around?

---

<div class="post-metadata">

**Author:** ![JasonCocke86858](https://avatars.discourse-cdn.com/v4/letter/j/d9b06d/32.png) [@JasonCocke86858](https://forums.knack.com/u/JasonCocke86858)\
**Post date:** [January 4, 2016, 6:23am UTC](https://forums.knack.com/t/filtering-views-on-fields-being-equal/7798/3 "2016-01-04T06:23:06Z")

</div>

Thanks Brad unfortunately that isn't a solution for us. We couldn't find a solution that would allow us to filter views on unstipulated content, i.e. filter Table A on Field\_1260 where it equals field\_1256 from Table B for logged in user X. The helpdesk suggested rendering the views outside of knack but for us where we need this for so many views, it became impractical, sadly we are now in the process of moving over to another software provider.

---

<div class="post-metadata">

**Author:** ![BradStevens](https://sea2.discourse-cdn.com/flex020/user_avatar/forums.knack.com/bradstevens/32/140_2.png) [@BradStevens](https://forums.knack.com/u/BradStevens)\
**Post date:** [January 2, 2016, 10:36pm UTC](https://forums.knack.com/t/filtering-views-on-fields-being-equal/7798/4 "2016-01-02T22:36:10Z")

</div>

Jason,

I would be thinking of the database & view structure:

1. Create a view that displays the top level records connected to the logged in user - say field\_1256 in a table. [http://helpdesk.knackhq.com/support/solutions/articles/5000443970-showing-records-connected-to-the-logged-in-user](http://helpdesk.knackhq.com/support/solutions/articles/5000443970-showing-records-connected-to-the-logged-in-user)

2. Then show that record on a single view and add a table displaying the child records for what you need.

I have a feeling it isn't as simple as that for what you're trying to achieve?

---

<div class="post-metadata">

**Author:** ![BennetSt.L83204](https://avatars.discourse-cdn.com/v4/letter/b/848f3c/32.png) [@BennetSt.L83204](https://forums.knack.com/u/BennetSt.L83204)\
**Post date:** [January 2, 2016, 6:44pm UTC](https://forums.knack.com/t/filtering-views-on-fields-being-equal/7798/5 "2016-01-02T18:44:52Z")

</div>

I'm trying to work on this myself - If someone has a way to do it, I'd love to hear it.
