# Hide choices based on criteria

**URL:** <https://community.glideapps.com/t/hide-choices-based-on-criteria/76830>\
**Category:** Ask for Help\
**Created:** [October 4, 2024, 4:02am UTC](https://community.glideapps.com/t/hide-choices-based-on-criteria/76830 "2024-10-04T04:02:05Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Bleu.Elefant](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/bleu.elefant/32/40086_2.png) [@Bleu.Elefant](https://community.glideapps.com/u/Bleu.Elefant)\
**Post date:** [October 4, 2024, 4:02am UTC](https://community.glideapps.com/t/hide-choices-based-on-criteria/76830/1 "2024-10-04T04:02:05Z")

</div>

I have several choice fields with the same source. I want to hide that choice item if it already exists in 2 fields already.

My usage is for a team form where a player can only be selected a maximum of 2 times for any given match.

PS I also want to limit the number of times a player can be selected in a match using multiple criteria i.e. Maximum time a player can be selected for Singles, maximum times a player can be selected for Doubles and total maximum times a player can be selected.

---

<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:** [October 4, 2024, 5:15am UTC](https://community.glideapps.com/t/hide-choices-based-on-criteria/76830/2 "2024-10-04T05:15:01Z")

</div>

> [@Bleu.Elefant](#):
>
> I have several choice fields with the same source. I want to hide that choice item if it already exists in 2 fields already.

The only way I can think of to do that would be with a Custom Form. With a Custom form you would be writing the choice values to User Specific columns, so you could use those in Data Editor logic to apply the filtering, like so:

- Use a Make Array column to create a single array from all of the target User Specific columns
- In your Choices table, create a multiple relation that matches each choice with the Make Array column
- Do a rollup through that relation to obtain a count
- You can now use the rollup as a filter on each choice component (eg. “count is less than 3”)
