# Check if current specific row entries match before adding new ones

**URL:** <https://community.glideapps.com/t/check-if-current-specific-row-entries-match-before-adding-new-ones/58809>\
**Category:** Ask for Help\
**Created:** [March 6, 2023, 8:31am UTC](https://community.glideapps.com/t/check-if-current-specific-row-entries-match-before-adding-new-ones/58809 "2023-03-06T08:31:33Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![Alexandru\_Giuseppe\_I](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/alexandru_giuseppe_i/32/40893_2.png) [@Alexandru\_Giuseppe\_I](https://community.glideapps.com/u/Alexandru_Giuseppe_I)\
**Post date:** [March 6, 2023, 8:31am UTC](https://community.glideapps.com/t/check-if-current-specific-row-entries-match-before-adding-new-ones/58809/1 "2023-03-06T08:31:33Z")

</div>

Hi there,

I’m having a row called “Song name” with fields like " Song name 1", “Song name 2” and so on. Every time I want to add new fields in that row I want to check if those entries already exist. And if those already exists to display a notification like “This was already shared by someone else”.

Is there any function that allows me to do this?

---

<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:** [March 6, 2023, 9:08am UTC](https://community.glideapps.com/t/check-if-current-specific-row-entries-match-before-adding-new-ones/58809/2 "2023-03-06T09:08:24Z")

</div>

Not exactly clear on what you want to do, but you can probably use component visibility:

> **[Glide • Visibility Conditions](https://www.glideapps.com/docs/reference/security-and-user-data/visibility-conditions)**
>
> Control who can view different elements of your app.

---

<div class="post-metadata">

**Author:** ![Alexandru\_Giuseppe\_I](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/alexandru_giuseppe_i/32/40893_2.png) [@Alexandru\_Giuseppe\_I](https://community.glideapps.com/u/Alexandru_Giuseppe_I)\
**Post date:** [March 6, 2023, 9:12am UTC](https://community.glideapps.com/t/check-if-current-specific-row-entries-match-before-adding-new-ones/58809/3 "2023-03-06T09:12:41Z")

</div>

@Darren_Murphy  
I want to check in tables if certain rows fields are matching.  
For example, let’s say I have a row called “Song name”, which contains these fields “Song name 1” and “Song name 2” and so on…

When I add to add a new song put the same song name as any of the above, to not allow me to do this.

Does this make any sense?

---

<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:** [March 6, 2023, 9:22am UTC](https://community.glideapps.com/t/check-if-current-specific-row-entries-match-before-adding-new-ones/58809/4 "2023-03-06T09:22:47Z")

</div>

Ah, I see. So you want to check for duplicates.

To do that, you need to use a [Custom Form.](https://community.glideapps.com/t/how-do-i-create-a-custom-form/25014)

---

<div class="post-metadata">

**Author:** ![Alexandru\_Giuseppe\_I](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/alexandru_giuseppe_i/32/40893_2.png) [@Alexandru\_Giuseppe\_I](https://community.glideapps.com/u/Alexandru_Giuseppe_I)\
**Post date:** [March 6, 2023, 9:30am UTC](https://community.glideapps.com/t/check-if-current-specific-row-entries-match-before-adding-new-ones/58809/5 "2023-03-06T09:30:05Z")

</div>

@Darren_Murphy  
I think it might be something along those lines, but you kind of lost me there. 😵‍💫

---

<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:** [March 6, 2023, 9:36am UTC](https://community.glideapps.com/t/check-if-current-specific-row-entries-match-before-adding-new-ones/58809/6 "2023-03-06T09:36:51Z")

</div>

Well, with a Glide native form there is no way to check for duplicates, because data isn’t added to the table until the form is submitted, and by that time it is too late.

A custom form is different. A custom form is built on a standard details screen, and the user inputs are collected in User Specific Columns, and then when the user submits the form these values are taken and used to add a new row.

And because you have the values in the table before the form is submitted, you can use them to check for duplicates. The way to do that is to create a relation from the User Specific Column to the corresponding column in the target table, and if that relation is not empty, then you have a duplicate. And so at that point, you can warn the user and stop them from submitting the form.

---

<div class="post-metadata">

**Author:** ![Alexandru\_Giuseppe\_I](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/alexandru_giuseppe_i/32/40893_2.png) [@Alexandru\_Giuseppe\_I](https://community.glideapps.com/u/Alexandru_Giuseppe_I)\
**Post date:** [March 6, 2023, 9:52am UTC](https://community.glideapps.com/t/check-if-current-specific-row-entries-match-before-adding-new-ones/58809/7 "2023-03-06T09:52:19Z")

</div>

Thanks, @Darren_Murphy, this is much clearer.  
Now I need to hrie a Glide expert to help me with this one as I’m not super familiar with how everything works in Glide so far.

---

<div class="post-metadata">

**Author:** ![system](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/system/32/53398_2.png) [@system](https://community.glideapps.com/u/system)\
**Post date:** [March 7, 2023, 9:52am UTC](https://community.glideapps.com/t/check-if-current-specific-row-entries-match-before-adding-new-ones/58809/8 "2023-03-07T09:52:47Z")

</div>

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.
