Hello Everyone, I have a form that has two de...

(Janet Palermo) #1

Hello Everyone, I have a form that has two dependent dropdowns, was wondering if I could make the second dependent dropdown a distinct value dropdown as well?

In my table I have multiple unit #s associated to specific tasks, I would like that once a unit/task has been selected/saved that the task will no longer appear in the dropdown box on the form.

(Jonas /) #2

just use the valid_if of the column you want to show the distinct values in.

select(table_name[column_name],

“filter,that results in true/false”,

“optional 3rd argument true=distinct based on [column_name]” )

of course you dont have to use the 3rd argument of the select, a normal select will do just fine.

if you want to filter the dropdown values based on another column, just include that column in your select() statement.