# Please help me add a distance constraint between two data types in a repeating group

**URL:** <https://forum.bubble.io/t/please-help-me-add-a-distance-constraint-between-two-data-types-in-a-repeating-group/189046>\
**Category:** Database\
**Created:** [January 31, 2022, 4:37am UTC](https://forum.bubble.io/t/please-help-me-add-a-distance-constraint-between-two-data-types-in-a-repeating-group/189046 "2022-01-31T04:37:20Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![kryptoluna1234](https://sea1.discourse-cdn.com/bubble/user_avatar/forum.bubble.io/kryptoluna1234/32/116742_2.png) [@kryptoluna1234](https://forum.bubble.io/u/kryptoluna1234)\
**Post date:** [January 31, 2022, 4:37am UTC](https://forum.bubble.io/t/please-help-me-add-a-distance-constraint-between-two-data-types-in-a-repeating-group/189046/1 "2022-01-31T04:37:21Z")

</div>

Hey everyone!

I am working on a project where a user matches with another user. These potential matches are displayed through a repeating group. The problem I am struggling with is how to add a constraint to the repeating group so that these potential matches are located less than or equal to 25 miles away from the current user (who is the one looking to click the potential match)

I have created a video quick video below to explain the problem. Please help if you know how to do this!

[![](https://img.youtube.com/vi/BljR9sjsaxs/maxresdefault.jpg "Please help with sorting the distance between two data types in a repeating group") ](https://www.youtube.com/watch?v=BljR9sjsaxs)

---

<div class="post-metadata">

**Author:** ![siddharth](https://sea1.discourse-cdn.com/bubble/user_avatar/forum.bubble.io/siddharth/32/99706_2.png) [@siddharth](https://forum.bubble.io/u/siddharth)\
**Post date:** [January 31, 2022, 6:10am UTC](https://forum.bubble.io/t/please-help-me-add-a-distance-constraint-between-two-data-types-in-a-repeating-group/189046/2 "2022-01-31T06:10:34Z")

</div>

Hello, @kryptoluna1234  
I have done a similar thing so I think I can help you.

1.Create a address field in user, make sure it’s set as geographical address type.  
2. Ask your users to enter their address in a searchbox input set to geographical address and save it to the step 1 created address field.  
3. In repeating group\> search for users\> where address is within 25 miles.

Done 🕶

Make sure you enter all maps API keys required for this functionality.

---

<div class="post-metadata">

**Author:** ![kryptoluna1234](https://sea1.discourse-cdn.com/bubble/user_avatar/forum.bubble.io/kryptoluna1234/32/116742_2.png) [@kryptoluna1234](https://forum.bubble.io/u/kryptoluna1234)\
**Post date:** [January 31, 2022, 5:54pm UTC](https://forum.bubble.io/t/please-help-me-add-a-distance-constraint-between-two-data-types-in-a-repeating-group/189046/3 "2022-01-31T17:54:39Z")

</div>

Thank you @siddharth!!

This makes much more sense. I am going to try this when I get to my computer and let you know how it works. Thanks
