Reference that repeat

I’m just starting with AppSheet and facing a problem for which I haven’t found a solution yet.

I’m developing an asset management app where I have multiple companies, each with various pieces of equipment, and each piece of equipment has its own maintenance history.

The relationship between equipment and company is working correctly; however, there’s an issue with the relationship between maintenance and equipment. I created a form for maintenance, and in this form, the “Ref” field for equipment only returns one specific piece of equipment, multiple times. This equipment isn’t even the first entry in the list – it’s the 13th row.

Could anyone help me with this?

What is the Ref column Equipamiento pointing to?

Try the following:

  1. Regenerate tables.

  2. Check the reference of the Equipamiento column.

  3. Review the datasource to ensure there are no duplicate IDs and that the records are distinct.

1 Like

See images below. One shows the repeated equipment, and the other shows the form, along with the tables with references.

Please post a screenshot of the column configuration for the Equipment column of the Maintenance table, and a screenshot of its Valid if and/or Suggested values expressions.

1 Like

Are these the screenshots you need?

1 Like

Yep, that’s what I wanted. Thanks!

I don’t see anything that would account for the behavior you’re getting. Therefore, I’m afraid I’m going to have to refer you to AppSheet Support for further help with this. Good luck.

1 Like

I found where the error was: it was in the data type of the ID column in the Equipment table. It was set as a number, but it should have been text. Thank you for the guidance.

1 Like

Good catch!