Skip to main content

Notifications

Dynamics 365 Community / Forums / Sales forum / Advanced Filter Based ...
Sales forum
Suggested answer

Advanced Filter Based On Value In Different Table

Posted on by 13
I have a Users table with a column for /Service Type/, for simplicity reasons imagine it looks like this:
 
UserService TypeGeoArea
Person1ServiceType1, ServiceType2Denver, Colorado Springs
Person2ServiceType2, ServiceType3Los Angeles, San Diego
Person3ServiceType4Denver, Colorado Springs
 
In an Orders table, I also have a column for service area, a simplified version would be this
 
OrderNumberServiceTypeGeoArea
101ServiceType2Denver
102ServiceType4Denver
103ServiceType2San Diego
104ServiceType3San Diego
 
Is there a way to create a view of orders with a filter where the Service Type and the Geo Area of the user is the same as the order?
In the advanced find, I can find  on the Orders, I can find the User table, but I can't create a filter that does something like this:
 
Order.ServiceType = User.ServiceType
Order.GeoArea = User.GeoArea
 
The problem is that in Advanced Find, when tell it to look at the Service Type on the order, I am forced to enter or select an actual value from the table and I can't tell it to look at a different table to compare values..
 
In essence I'm trying to create a view that will filter based on who is looking at it... this way if Person1 is looking at the view, they would only see orders in Denver and Colorado Springs that have Service Type 1 or Service Type 2. 
 
Any ideas?
  • Suggested answer
    Dengliang Li Profile Picture
    Dengliang Li Microsoft Employee on at
    Advanced Filter Based On Value In Different Table
    Hi,
     
    Based on the information you provided, conducted some tests.
    Take the values of ServiceType and GeoArea attributes in User as conditions, filter them in the Order table, and manually assign the filtered Views to the corresponding User.
    In this way the User can see the View that matches the criteria.
    The steps are as follows.
    Step 1. Add the view filter criteria for the Order entity.
    1. Here take user 'Bruce Lee' as an example.

     
    1. This is the view of Order entity.

     
    1. The filter conditions are as follows.

     
    Step 2. Save the filtered views and assign them to the corresponding users.
    1. This is the view after filtering, which meets the expected conditions.

     
    1. An asterisk beside the view name indicates you edited the view and haven't saved it. Therefore, save it and name it.

     
    1. Assign the saved new view to a user.

     



    I hope my answer is helpful to you! If you have any other questions, please feel free to contact me.
     
    Best Regards,
    Dengliang Li

Helpful resources

Quick Links

Dynamics 365 Community Update – Sep 9th

Welcome to the next edition of the Community Platform Update. This is a weekly…

Announcing Our 2024 Season 2 Super Users!

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

Leaderboard

#1
André Arnaud de Calavon Profile Picture

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

#2
Martin Dráb Profile Picture

Martin Dráb 227,996 Super User 2024 Season 2

#3
nmaenpaa Profile Picture

nmaenpaa 101,148

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans