Skip to main content

Notifications

Announcements

No record found.

Dynamics 365 general forum
Suggested answer

OOB Lookup filtering not working for self referential lookup

Posted on by 5

Hello Folks,

I have a custom lookup field "Region (of type Team entity)" on the Team entity itself (i.e. have created a self-referential relationship (1: N) on Team entity).

And I also have a lookup field "Employee" of custom entity Employee on Team entity as shown below:

pastedimage1633247806122v2.png

Now, I want to filter Employee lookup based on the Region selected.

But in Related records filtering it does not show the Region Lookup field i.e. self-referential lookup, see screenshot below:

 pastedimage1633247790537v1.png

Note: I do not want to use custom javascript code.

 

Query:

Why I am not able to see the Region lookup (of type Team entity) in the Related records filtering list? Self-reference might be causing the problem, but anyone has an idea why this isn't working.

 

Any help will be appreciated.

 

Thank you

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: OOB Lookup filtering not working for self referential lookup

    Hi Partner,

    Can you click Yes under "Did this answer your question?" to close this thread if my answer is helpful.

     pastedimage1634111835744v1.png

    Thanks. 

  • Suggested answer
    Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: OOB Lookup filtering not working for self referential lookup

    Hi Dustin,

    Related Records Filtering under Field Properties can filter lookups for 1:N and N:N relationships.

    But Employee lookup field means that Team and Employee is N:1 relationship,  One team(child) can only have one employee(Parent).

    You can filter region based on employee, but the opposite is impossible.

    pastedimage1633315018697v1.png

    If you want to populated employee field with value from parent team record once region field is filled in current team form automatically, you can achieve it through flow or js code.

  • Dustin Kodli Profile Picture
    Dustin Kodli 5 on at
    OOB Lookup filtering not working for self referential

    Hello Folks,

    I have a custom lookup field "Region (of type Team entity)" on the Team entity itself (i.e. have created a self-referential relationship (1: N) on Team entity).

    And I also have a lookup field "Employee" of custom entity Employee on Team entity as shown below:

    pastedimage1633247490539v1.png

    Now, I want to filter Employee lookup based on the Region selected.

    But in Related records filtering it does not show the Region Lookup field i.e. self-referential lookup, see screenshot below:

     pastedimage1633247511245v2.png

    Note: I do not want to use custom javascript code.

     

    Query:

    Why I am not able to see the Region lookup (of type Team entity) in the Related records filtering list? Self-reference might be causing the problem, but anyone has an idea why this isn't working.

     

    Any help will be appreciated.

     

    Thank you

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Anton Venter – Community Spotlight

Kudos to our October Community Star of the month!

Announcing Our 2024 Season 2 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Dynamics 365 Community Newsletter - September 2024

Check out the latest community news

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 290,554 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 228,588 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,148

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans