Skip to main content

Notifications

Announcements

No record found.

Customer experience | Sales, Customer Insights,...
Suggested answer

How to filter a dataverse table on the basis of another dataverse table with list rows action in powerapps flows?

Posted on by 35

I have a two tables in my solution , Table Employee which is like a employee master to keep the records of all employees and second table is taskTable which will be used to enter details of new task done by an employee , now I want to check this list from taskTable and want to compare the employee names with the Employee table which has all employees name in it and whoever is missing from the list of Table Employee , i want to send an email reminder to those ..
If I try to list rows first for taskTable and then list rows for Employee table it is not giving the proper output instead it is checking for each value from taskTable to every other value in Employee table and bcoz of that it is returning unexpected results ,
can anyone help please?

  • Suggested answer
    rahul78610 Profile Picture
    rahul78610 35 on at
    RE: How to filter a dataverse table on the basis of another dataverse table with list rows action in powerapps flows?

    Thank you everyone for your responses , I tried with my employeetask table first with list rows and then again took the list rows action for employee table and then compare the names with the list which i got from employeetask table and whoever was not there in task table, I just send the email  and it worked.

  • Suggested answer
    Leah Ju Profile Picture
    Leah Ju Microsoft Employee on at
    RE: How to filter a dataverse table on the basis of another dataverse table with list rows action in powerapps flows?

    Hi rahul78610,

    Based on your description, "second table is taskTable which will be used to enter details of new task done by an employee"

    The employee and taskTable have 1:N relationship, there is one employee lookup column in taskTable, Right?

    pastedimage1672713218536v1.png

    pastedimage1672714425004v2.png

    What you want is a list of employees who do not have any related tasks, Right?

    pastedimage1672715330769v4.png

      
        
        
        
        
        
        
          
        
      
    

    Filter in the flow:

    pastedimage1672715563078v5.png

    Next Steps:

    pastedimage1672716086850v6.png

    Test Result:

    pastedimage1672716185158v7.png

  • Suggested answer
    Bipin D365 Profile Picture
    Bipin D365 28,964 Super User 2024 Season 1 on at
    RE: How to filter a dataverse table on the basis of another dataverse table with list rows action in powerapps flows?

    Hi,

    Try below filter in advanced find and download fetch XML which can be used in your power automate list rows

    IMG20230102181352.jpg

    Please select Does not contain data in related filter.

    Select Employee where I have contacts and select Task when I selected Email

  • Suggested answer
    Mohamed GRAIB Profile Picture
    Mohamed GRAIB 2,498 Super User 2024 Season 2 on at
    RE: How to filter a dataverse table on the basis of another dataverse table with list rows action in powerapps flows?

    Hi rahul78610  

    You can Utilize the List rows action, and mention this fields : 

    pastedimage1672662559406v1.png

    In the Select columns field, you mention the shema name of columns that you want export. 

    And then, you will navigate to your Dynamics 365 and navigate the advanced search 

    pastedimage1672662632805v2.png

    You will search all employees and in the filter you add a related table (Tasks) and Guid (Tasks table) does not contain data. 

    pastedimage1672662824616v3.png

    Then you will click on Download Fetch XML query 

    You will add this Query in your Power automate action 

    pastedimage1672662895162v4.png

    Hope that's helpful for you 

  • rahul78610 Profile Picture
    rahul78610 35 on at
    RE: How to filter a dataverse table on the basis of another dataverse table with list rows action in powerapps flows?

    Hi Mohamed GRAIB , I need the list of all employee names who have not filled any data in the other table so basically want just those rows for employees who have not filled anything in the taskTable and need to get those names from employee table

  • Suggested answer
    Mohamed GRAIB Profile Picture
    Mohamed GRAIB 2,498 Super User 2024 Season 2 on at
    RE: How to filter a dataverse table on the basis of another dataverse table with list rows action in powerapps flows?

    Hi Rahul,

    In the action List rows of your table Task rows, rou can add a filter like this 

    pastedimage1672661326456v1.png

    You will List rows of Tasks where the employee field is not Nul. 

    Hope that's helpful for you

  • Suggested answer
    Abdul Wahab Profile Picture
    Abdul Wahab 12,070 Super User 2024 Season 1 on at
    RE: How to filter a dataverse table on the basis of another dataverse table with list rows action in powerapps flows?

    Hi rahul78610,

    Use the below components in the Power Automate

    1. Recurrence. For more details: https://learn.microsoft.com/en-us/power-automate/run-scheduled-tasks
    2. List rows with Filter rows or Fetch XML Query. For more details: https://learn.microsoft.com/en-us/connectors/commondataserviceforapps/#list-rows
    3. Condition. For more details: https://learn.microsoft.com/en-us/power-automate/desktop-flows/use-conditionals
    4. Send an email (V2). For more details: https://learn.microsoft.com/en-us/connectors/office365/#send-an-email-(v2)

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

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,280 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,235 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans