enter image description here

I want to add a lookup filter for the lookup between Package Version and Release. So I just can choose Releases which are linked to the same Program as my related Package.

This is not possible according to this document:

You can only choose related fields that are one relationship away from the lookup object.

I want to bypass this issue with a formula field, but the problem here is the missing possibility to compare a text field with lookup field within lookup filters(documentation).

How can I tackle this?

  • What about adding the program field to the package version object and prepopulating it when generating the package version from the package's program and using that to filter again the releases program?
    – Jenny B
    Commented Jan 13, 2016 at 21:04
  • It is not allowed to use trigger and similar stuff within the LMA package environment.
    – David Renz
    Commented Jan 14, 2016 at 16:44
  • You can use validation rules instead. salesforce.stackexchange.com/questions/246104/… Commented Feb 16, 2023 at 9:43

1 Answer 1


Try this

  1. Create a formula field on package version object and which gets the program value for the related Package record. Something like this


  2. Create another formula field on Release object to get the related Program value.


  3. Create a lookup filter to match both of these values.

Select field in the Value/Field section of the filter editor and it will let you to compare with Version record.

Hope this helps !!

  • 1
    You can't compare two (fomula) text fields within a lookup filter.
    – David Renz
    Commented Jan 14, 2016 at 16:40

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .