How do I present a selection of values in a drop-down in the RDM create/edit screens.
E.g. I have an entity called Door with a column called state that can have a value of either Open or Closed. Can this be presented as a drop down to a user?
Best answer by OjaswiniView original
If I am understanding the question correctly, you are talking about some parent child relationship where one column values in child table, should come from predefined values from master table. You can use Drop Down capabilities for that column in child table. you need to mention this in the Relationships of parent -child table. You can choose combo or window.
I hope this will resolve your issue.
Hi - I was hoping to find a way to present a drop down list without having to create an additional table. Returning to my original example of the Door and its State attribute, I want to avoid creating a Door_State table with just two values and a relationship between it and the Door table.
At the moment the only solution for drop down is to create a separate table which will act as parent table to your Door table.
A way around it is to create an expression validation in that table, only allowing those 2 values, and putting that also in the error message to let the users know that these are the only 2 values allowed.
But this means, if you need to add to the allowed values in the future you will need to do a model change.
We have seen similar use case implemented with a generic “picklist” table, with columns “table_name” and “value”, so e.g.
Then at your Door table, you relationship would use picklist table as a parent, and use filter table_name = ‘Door’
So you can have all of these little “bits” of ref codes in a generic picklist table and you won’t need to create loads of them.
What do you think? Would this work for you?