function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
ArmanArman 

How to create a Lookup field to read values from the same table

Hi,

I'd like to have a lookup field in my table which looks up a value in the same table. For example, a record will have a parent if there is another record with an ID equal to that specified in the "ParentID" field of the original record. Otherwise the record is a root level record.

I really don't want to make more custom objects for this task. However, when I try to create a new lookup custom field it won't allow me to choose the same table as the one I'm trying to create this field for. The reason for not going with multiple tables is because this way I can build a hierachy of infinite nodes similar to a tree data structure where each record may be the start of a new tree or be a branch of a tree.

Could someone please direct me?

Thanks in advance.