In my equipment form I have dependant drop downs that you first choose the object type and then the class, there is also a field called fleet that I want to filter it down on based on an earlier y/n question if the equipment is fleet
I did this previously: on the data validity EquipClass[Object Type] and EquipClass[Class] on the data table
but how do I also make it filter on the fleet column based on the previous answer in the form?
Solved! Go to Solution.
To the best of my recollection, the pattern for dependent dropdown Valid If expressions is:
SELECT(
MyTable[ColumnA],
TRUE,
TRUE
)
SELECT(
MyTable[ColumnB],
([_THISROW].[ColumnA] = [ColumnA]),
TRUE
)
SELECT(
MyTable[ColumnC],
AND(
([_THISROW].[ColumnB] = [ColumnB]),
([_THISROW].[ColumnA] = [ColumnA])
),
TRUE
)
SELECT(
MyTable[ColumnD],
AND(
([_THISROW].[ColumnC] = [ColumnC]),
([_THISROW].[ColumnB] = [ColumnB]),
([_THISROW].[ColumnA] = [ColumnA])
),
TRUE
)
and so on.
I can get the first dropdown to work with:
SELECT( EquipClass[Object Type], ([fleet] = [_THISROW].[Fleet]) )
but then the dependent dropdown is no longer dependent
so I guess I need another select that filters on both Fleet and Object Type
working on figuring it outโฆ
To the best of my recollection, the pattern for dependent dropdown Valid If expressions is:
SELECT(
MyTable[ColumnA],
TRUE,
TRUE
)
SELECT(
MyTable[ColumnB],
([_THISROW].[ColumnA] = [ColumnA]),
TRUE
)
SELECT(
MyTable[ColumnC],
AND(
([_THISROW].[ColumnB] = [ColumnB]),
([_THISROW].[ColumnA] = [ColumnA])
),
TRUE
)
SELECT(
MyTable[ColumnD],
AND(
([_THISROW].[ColumnC] = [ColumnC]),
([_THISROW].[ColumnB] = [ColumnB]),
([_THISROW].[ColumnA] = [ColumnA])
),
TRUE
)
and so on.
Since the output is already filtered by the Fleet in the first drop down I didnโt need the AND
This made it work. I may add it as you have shown if that makes any difference.
Select (
EquipClass[Class],
( [Object Type] = [_THISROW].[AssetType] ),
True
)
Please note that spreadsheet filters may/will affect AppSheetโs ability to see your data. I would advise against using spreadsheet filters in a worksheet used by an app.
User | Count |
---|---|
32 | |
31 | |
30 | |
19 | |
16 |