In edit/insert mode, how can I see a list of possible values for a field, based on some foreign table?
You have to setup appropriate links between the tables, and also setup the “display field” in the foreign table. See FAQ 6.6 for an example. Then, if there are 200 values or less in the foreign table, a drop-down list of values will be available. You will see two lists of values, the first list containing the key and the display field, the second list containing the display field and the key. The reason for this is to be able to type the first letter of either the key or the display field. For 200 values or more, a distinct window will appear, to browse foreign key values and choose one.
You have to setup appropriate links between the tables, and also setup the “display field” in the foreign table. See FAQ 6.6 for an example. Then, if there are 100 values or less in the foreign table, a drop-down list of values will be available. You will see two lists of values, the first list containing the key and the display field, the second list containing the display field and the key. The reason for this is to be able to type the first letter of either the key or the display field. For 100 values or more, a distinct window will appear, to browse foreign key values and choose one. To change the default limit of 100, see $cfg[‘ForeignKeyMaxLimit’].
Related Questions
- The Ledger List of Values on the Run Financial Reports form shows all possible ledgers. How can this be limited to only ledgers the responsibility should access?
- In edit/insert mode, how can I see a list of possible values for a column, based on some foreign table?
- In edit/insert mode, how can I see a list of possible values for a field, based on some foreign table?