Lookup example

Suppose you have a extension field on the Main tab of an object that is called Primary Customer. You want the lookup for the Primary Customer field to show the same list of customers that are displayed in the References tab of the object. In this case, complete these steps.

  1. Create this query in the Query form.
    SELECT R_OBJECT_KEY, R_OBJECT_DESC FROM FSOBJECTREFERENCE WHERE 
    OBJECT_TYPE = [%OBJECTSYMBOL] AND OBJECT_KEY = [%OBJECTKEY] AND 
    R_OBJECT_TYPE = 'CUSTOMER';
    
  2. Create the new lookup in the Lookup Set form. In the Lookup Language tab, specify Primary Customer for the Title and Line Label.
  3. Add the Lookup Code to the extension field in the Symbol > Extensions tab.