Lookup Data Type
Organizations deal with a large number of entities such as users, customers, vendors, items and projects. There’ll be cases when you might want to compare and track any two entities.
Let’s say you want to measure the efficiency of users in your organization by choosing to track the number of customers each user adds. To do this, you would need to link the users and customers module. This linking is made possible by a datatype called the Lookup in Zoho Books.
To understand this better, let’s look at two scenarios where the Lookup datatype can come into play.
Scenario: Patricia wants to keep track of all the sales/purchase transactions a user creates on a regular basis. She creates a custom field in the sales/purchase module with Lookup data type and selects the module as Users. After this, whenever she creates a transaction for that module, she can assign it to a specific user. By the end of the week when Patricia wants to check the number of transactions created by different users, she goes to the Users and Roles module and tracks them under the users’ Related List.
Scenario: Patricia owns a retail store she wants to keep track of all bags of rice (Items) that are purchased from a particular vendor (Contacts). To keep track of it, she creates a custom field in Items module with the Lookup data type and selects the module to track as Contacts. When she adds the bags of rice as an item, she can assign the corresponding vendor to it. Now, to track all the purchases made for the bags of rice from a particular vendor, she goes to the Contacts module, selects the vendor and views the number of rice bags purchased under the vendor’s Related List.
You can add custom fields with the Lookup data type for different modules in their Preferences section (Settings > Select the module > Field Customization > + New Custom Field).
Let us see how we can implement Scenario 1 and create a custom fileld with lookup data type in a module.
- Go to Settings on the top right corner of the page.
- Select the module for which you want to add a lookup field (in this case, the Sales/Purchase modules).
- Select the Field Customization tab on top of the page.
- Click the + New Custom Field button on the top right corner of the page.
- Fill in the following fields.
|Label Name||The field name which will appear in the module.|
|Data Type||The data type should be Lookup.|
|Help Field||A brief description on what the custom field is used for.|
|Module||The module in which you want to track the records (in this case, Users).|
|Related List Name||The name of the list which will appear in the looked-up modules (In Scenario 1, the related list will appear in the Users and Roles module).|
- Click Save.
The Related List with the lookup details will be available in the corresponding modules such as Items, Projects, Customers, Users, Invoices, Sales Orders, Purchase Orders, and Custom Modules. To access the related list:
- Go to any one of the above modules in which you have set up the lookup field (in this case, Users and Roles).
- Select the Related List tab from the Details page (select a user and then click Related List).
All the related entries can be accessed from this page.
Insight: In Scenario 1, the lookup field is created for a Sales/Purchase module and assigned to the module Users. The Related List will be tracked and available in the Users and Roles module.