how do i take two columns in a form, first one referencing a table, second one referencing a different table. the options for answer in second one should be filtered based on the first answer? For example i have a table called States with columns ID, STATE and a table named Cities with columns ID, CITY, STATE. In the Cities table the STATE value is the ID of the STATE from the States table. When user chooses the State in the dropdown on the form, the city options should only be cities within that state. I've been able to accomplish this by referencing my state table for State field on the current table, and referencing my cities table for my City field on current table. I then add a vaid if statement of SELECT(Cities[CITY], [STATE] = [_THISROW].[State]). It is showing the filtered cities correctly, however they all have yellow triangles next to them. I'm stumped on how to fix that.
Solved! Go to Solution.
I was able to fix it by putting ID instead of CITY. SELECT(Cities[ID], [STATE] = [_THISROW].[State])
It's because your SELECT statement is not returning the key value from the cities table. Ref columns require key values. Change SELECT(Cities[City] to FILTER(Cities
combine those two tables into one.
This is called "Appsheet's Easy Dependent Dropdown Solution".
Search it on YouTube. You'll be happy as to how simple it actually is. You cam evem have 10 fields all with options dependent on the selection of the previous one before it.
I was able to fix it by putting ID instead of CITY. SELECT(Cities[ID], [STATE] = [_THISROW].[State])
Which is essentially the same thing that I recommended.
yes, I just chose the wrong column
User | Count |
---|---|
35 | |
30 | |
30 | |
20 | |
18 |