Skip to main content

Notifications

Announcements

No record found.

Business Central forum
Suggested answer

Filtering rows based in jobs listing

Posted on by 40
Hello There,
 
I need to filter the jobs list based on two conditions : 
1. If the job's created by user matches the logged in user
2. If the customer's Sales Person (Customer in job page) , matches the logged in user
 
jobs matching both conditions should be listed in jobs listing page.
 
First condition is achievable using Filter groups.  (https://yzhums.com/8427/)
 
How to achieve the second condition? Anybody please guide 
 
Thank for your help!
Categories:
  • Charles Profile Picture
    Charles 4 on at
    Filtering rows based in jobs listing
    There are several ways to filter rows based on job listings. One method is to use a spreadsheet program like Microsoft Excel or Google Sheets. These programs have built-in filters that can be used to filter rows based on a variety of criteria.Another method is to use a database program like MySQL or Oracle. These programs have more advanced filtering capabilities than spreadsheet programs.
  • Dej Profile Picture
    Dej 40 on at
    Filtering rows based in jobs listing
    Thank you for your assistance Yun Zhu.
    I learned many things from yhums.com!. I have already referred that link. it didn't help. If it is a complete custom listing page, that method works. unfortunately, I have to use those filters on Job Extension Page .
     
    as mentioned in the site,  Record.FilterGroup(-1) cannot be used to add default filter in OnOpenPage trigger.
     
    Now I have created two seperate record buffers one buffer for filtering records based on systemcreatedby
    and another buffer for filtering records based on assigned to sales person. concatenating all those job numbers with '|'
     
    use this concatenated job numbers as the records filter Rec.SetFilter('No.',Concatenatedjobs) together with filter group.
    but i am not sure this is correct or not.
     
    Thank you once again if you can confirm the correctness of this method!
  • Suggested answer
    YUN ZHU Profile Picture
    YUN ZHU 68,480 Super User 2024 Season 2 on at
    Filtering rows based in jobs listing
    Hi, If you need cross-search between different fields, you can use the following method.
    Cross-column search (OR filters on multiple fields) ★FilterGroup(-1)
     
     
    Hope this helps.
    Thanks.
    ZHU

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,263 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 228,112 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,148

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans