Customizing the Lookup List
When a foreing key (a field that relates the currently edited record into a form with anothers talbe record) is displayed, then automaticaly a lookup list is displayed. This automaticaly created list contains from the related table not only the lookuped field but also any other fields of the related table that are displayed also on the form.
For example the following sniped of code does the customization:
start_sql "EID_SEL" "KOSMOS"
SELECT PRODUCT.DESCR, PRODCUT.P_ID AS RMAT, PRODUCT.APRICE2,
WHERE (((EIDH0.PERIGR) Like :E & "%")
ORDER BY EIDH0.PERIGR