Related records not showing up as linked to parent table - Appsheet <> Airtable

Problem

Related records to a table don't show up as "linked" to its parent table. The creation of the records and the "linking" to the parent record in Airtable both work well. 

Nonetheless, even if they are all correctly linked in Airtable, the relation doesn't show up in AppSheet.

Context & structure

I have 4 tables:

Screenshot_2022-09-07_at_10_29_18.png

 

 

 

Incoming: where the incoming item is registered when it's received. Refs to Manufacturers and Unit are in place to select  the respective linked records in the tables (in Airtable).

Components: Table that "is part of" Incoming. Basically, they are the components of which an item in Incoming is made of. 

Screenshot 2022-09-07 at 10.30.14.png

 

 

 

 

 

 

It is connected to the Incoming via the "Incoming Link" column. These are the settings for the field/column

 

Screenshot 2022-09-07 at 10.30.24.png

 

 

 

 

 

 

 

As mentioned above, when creating an "Incoming record" and its components with the Incoming_From, everything works well. All the rows are created in Airtable, respectively the main record in the "Incoming" table and the related components in the "Components" table. All the records are correctly linked together:

 

Screenshot 2022-09-07 at 10.32.05.png Screenshot 2022-09-07 at 10.32.48.png

 

 

 

Nonetheless, even if AppSheet manages to create and link everything, the relationship doesn't show up in AppSheet.The Related Components are always 0:

 

Screenshot_2022-09-07_at_09_58_38-2.png

 

These are the relevant column settings in the "Incoming" table:

 

Screenshot 2022-09-07 at 10.29.44.pngScreenshot 2022-09-07 at 10.30.01.png

 

 

Any idea about why AppSheet doesn't see them as linked? Is there anything I'm missing?

Thanks!

0 11 355
11 REPLIES 11

Steve
Platinum 5
Platinum 5

I'm completely confused.

In a new reply, please post and clearly label a screenshot of the columns of Incoming table as shown in Data >> Columns of the app editor.

Please also post and clearly label a screenshot of the columns of the Components table.

All of your references to Airtable are a bit confusing, since it suggests to me you're using some special feature of Airtable. If so, please clearly identify the special feature. If not, that you are using Airtable should have no bearing on your problem.

 

Hi Steve,

Thanks for the reply; I'll try to be more precise.

Starting from Airtable, I'm not using any special Airtable feature; it's a "normal" (for Airtable, at least) "Link record" field. It allows linking a record in a table to one in another hence creating a SQL-like relation. (here you can find out more https://www.airtable.com/guides/build/connect-data-with-linked-records)

In my case, a record in the Incoming table is linked to one or more (one-to-many) records in the Components table.

Airtable

Here's a better explanation of the Airtable's screenshots:

airtable.jpg

The Incoming Table is the one on top. As you can see, the Incoming record with EntryID: 14-90622 has 4 Components records linked to it. The one-to-many relationship between Incoming and Components records is shown in both tables with Incoming having the 4 Components records (their IDs) shown in the Components column and each component record having the "Incoming Link" populated with their "parent" Incoming record ID. Again these relation columns are a core feature of Airtable, nothing special.

Appsheet

The Components table column structure is the following:

Screenshot 2022-09-08 at 18.18.41.png

It is linked to the Incoming table via the "Incoming Link" column. Here are the column's settings details:

Screenshot 2022-09-08 at 17.51.51.png

As you can see Components "Is part of" Incoming. 

The Ref relation works correctly both in Appsheet and Airtable. This means that in the Incoming creation form I can add as many Components as I wish and when I submit the form Appsheet is going to create one record in the Incoming table (in Airtable) and as many Components records as I've added in form in the Components table (in Airtable). Here you see the experience of adding a couple components in the Incoming Form:

record form.gif

As you can see, there's a warning sign but there's no mention anywhere (not even in Info > Errors) regarding what might be causing it. Anyway, the sign doesn't prevent from saving everything correctly as mentioned above.

The only missing piece of the puzzle is the Incoming table column structure. There are a lot of columns but the relevant ones are the Refs and the key/label. Here are three screenshots that shows the columns settings of pertinent columns of the Incoming table:

incoming1.jpg

Screenshot 2022-09-08 at 18.25.39.png

 incoming23.jpg

The Refs to Manufactures and Units refer to the two other tables as I mentioned in the original message and are most likely irrelevant in this matter. There's more than one field that refers to the Manufactures table but that is normal and non-problematic.

Conclusion

To quickly restate the issue: everything seems to be set up right and the creation of the records and the construction of their relation works. Nonetheless, when I go to the details of an Incoming record I always see "0 Related Components" even for the ones that I've just created successfully via the Incoming Form.

Screenshot_2022-09-07_at_09_58_38-2.png

 

Hope it's clear now ๐Ÿ˜‰ It might be related to the warning sign I've mentioned above but I don't have any error messages of any kind.

I appreciate the help!

Thanks

Did you change anything from the [Related Components] column? Can you share the AppFormula expression?

This may be related to a bug. Do the records appear after a sync?

Hi @SkrOYC ,

Thanks for the reply.

If you mean changed anything in the [Related Components] column settings, I'd say no. Here you have the formula: 

REF_ROWS("Components", "Incoming Link")

The records appear both in Incoming view and in the Components one. Nonetheless, if I click on a component detail the Incoming Link field has a warning and its ID is shown instead of the label.

Screenshot 2022-09-08 at 20.27.38.png

Clearly the issue is related to the relationship between the fields but I don't see how.

Cheers 

Seems like Airtable is changing the ID. Does AirTable has any ID generation stuff that could be turned off?

Resolved: Entry ID was both key and label and for whatever reason this messed up with the reference in AppSheet. 

That's a weird one, label is just there to show which record is being use but doesn't have any impact on the backend

I assume it's more related the relationship between the key being the Airtable ID and and a table being "part of".

I didn't have any issues having the Airtable ID as an AppSheet key before creating the relation between the two tables so most likely that's the cause. Tho it's not clear why, it might be related to how AppSheet handles that on the backend.



@giacomo_ wrote:

Airtable ID



@SkrOYC wrote:

Does AirTable has any ID generation stuff that could be turned off?


So, they have

Well yes Airtable is not a matrix like google sheet or excel is a relational database so each  record has (and must have) a unique ID that is generated on creation of the record. If you just use the UI you will never see it and you will just see the label that you picked for it (that you must picked nonetheless). 

So turning it off it's not an option and it's not possible since it would be like having a database entry without an ID to refer to.

I get it. The problem I see is that you are forced to use either AppSheet or AirTable.
I think that the AirTable option as datasource is like any other, just a way to have the data inside AppSheet but not a way to make possible the usage of your data from two places at once, that's what "AppSheet Databases" are meant to be.

In other words, unless I'm missing something, don't expect your data inside AirTable to be usable if you want to have a good AppSheet app and the other way around. Unless you can use the Airtable ID as your Key column, you have to forget about the relations being useful inside AirTable