How to reference a column from another table

I have a “staff directory” app and am making a HR report app and I want the name column to be a dropdown list that references the names in the “staff directory” list and can choose each one from a drop down. I have added the table to the app and I reference it but am not sure how to select the names column to populate that choices.

Solved Solved
0 11 6,027
1 ACCEPTED SOLUTION

I figured out my issue. I created an ID field in the A column but did not manually input anything into them. So without the ID “Key” field, it wasn’t pulling any records. Is there a way to have the system automatically assign ID fields to each row? Does it do this automatically when a new record is created by the app? I set up the sheet before hand in google sheets and then imported it to set it up.

View solution in original post

11 REPLIES 11

I believe you Don’t need to reference it.

Best bet is just to set the column type to text and in the valid if put Table Name[name Column]
Appsheet should intelligently recognize this and create a drop down list.

I tried your suggestion but it did not seem to work. I do not understand what I am doing wrong. I have the table inported and the name is Sheet1. I put Sheet1[Name] in my other table for the HR report in the valid if entry under Name. It does not even show the field in the app.

Is it set to visible?

this one is worked perfactly thanks alot i am finding this way from many days.

Steve
Platinum 4
Platinum 4




Yes, sometimes it will show and sometimes it won’t. But it won’t show a dropdown list populated with the names in the Names column when it does show. It will be just a blank box to type in. If I put the “Valid if” field populated with Sheet1[Name] then the field disappears.

Does your Name Column in Sheet one have any values?
Are there rows in this table?

Yes, it is populated with a list of names in that column.

I figured out my issue. I created an ID field in the A column but did not manually input anything into them. So without the ID “Key” field, it wasn’t pulling any records. Is there a way to have the system automatically assign ID fields to each row? Does it do this automatically when a new record is created by the app? I set up the sheet before hand in google sheets and then imported it to set it up.

Not after the fact, but you can do this yourself:

When the app itself adds rows, it will populate the key column with a unique identifier, but it’s up to you to tell AppSheet how to generate the identifier.

Thanks for your help!

Top Labels in this Space