Enumlist: Update & Reset based on another column value

Hello,

I have the following data structure:

Table → Cotiza
Column → cotizaTipo (Enum)
Column → tourID (EnumList)

Table → Tour
Table → Programa

Objective
The objective is that column tourID (EnumList) shows either the list of Tours or Programa based on the value of CotizaTipo

Progress so far
Based on the request I incorporated the following valid if expression:
IF([_THISROW].[cotizaTipo] = "Tours", Filter(Tour, TRUE), Filter(Programa, TRUE))

I also included a Reset on edit expression just to make sure that the EnumList will refresh its values if a change happened on cotizaTipo
[_THISROW_BEFORE].[cotizaTipo]<>[_THISROW_AFTER].[cotizaTipo]

The problem
So far the update of the EnumList doesn’t feel natural.
When I change between the values of cotizaTipo the list on tourID doesn’t update inmediatly.
It updates only when I select a few items, and then clear the list, which is odd.

It might be a little hard to understand so just in case I recorded the case:

Another thing I would like to ask is if we can show the label of the columnID instead of the ID itself.
For example, the Programa table has programID column as ID, but I would like to show programName column value in the EnumList dropdown, is it possible?

Thanks

Remove [_THISROW]. from that expression.

Thanks Steve,

I’m wondering if the second question is also possible:
Show the label of the table instead of the table ID.

Sure. Set the Base type for the EnumList column to Ref. Save the change. Return to the column’s config and set the Source Table (or is it Referenced table?) to the table referenced. Done!

Thanks Steve,

The only thing is that I’m not doing a reference to a single table, but to 2 of them: Tours and Programs, depending on the IF statement.

By doing your suggestion I would do the reference to only one of the tables

Probably my approach is not the best and maybe I need 2 EnumList, one for each table, and show/hide depending on the cotizaTipo value.

AppSheet has no support for that approach.