web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / How to get the results...
Power Apps
Answered

How to get the results from 3 lists

(0) ShareShare
ReportReport
Posted on by 517

Hi All,

I have 3 lists :

* Combined List : CombinedNumber and EmployeeID;

* Vehicle : CombinedNumber, RentalColumn ("Yes","No");

* Driver - EmployeeID and Department ("A","B", "C")
I want to have the CountRows() of the results of these 3 lists. How should my Filter() look like? Should I use a Lookup()?

 

e.g. There is 5 Employees (Department : B; RentalColumn : Yes).

 

Best Regards,

dKayt

Categories:
I have the same question (0)
  • royg Profile Picture
    on at

    Yes, you need to add 2 LookUp columns to your combined list:

    Something like:

    AddColumns(CombinedList, 
    	"EmpDepartment", LookUp(Driver, EmployeeID=CombinedList[@EmployeeID]).Department,
    	"VehicleRental", LookUp(Vehicle, CombinedNumber=CombinedList[@CombinedNumber]).RentalColumn)

    You can collect that into a collection and display in gallery or simply set the gallery items property to that expression.

    Now, you can Filter by the 2 added columns (EmpDepratment and VehicleRental) and count the returned rows or simply display the gallery itemscount property.

     

    Hope this helps

  • dkayt Profile Picture
    517 on at

    Hi,

    thanks for replying.

    I try this, I put it into a Collection and I get the entire CombinedList with 2 additionals columns.

    My Filter looks like this : 

     

    CountRows(Filter(CombineList, VehicleRental.Value = "Yes" And EmpDepartment.Value = "B"))

     

    Currently result : all the items from CombineList.

    What I want to see : Only 5 Items. 

     

    Do I miss something in my Filter()?

     

  • royg Profile Picture
    on at

    Perhaps it should be = "Yes" instead of = Yes

  • dkayt Profile Picture
    517 on at

    Even If I correct it. It doens'nt work like expected.

  • Verified answer
    dkayt Profile Picture
    517 on at

    Hi @royg 

    I find another way to resolve my problem, hopfully It can help someone too ^^

     

    OnVisible
    
    ClearCollect(colVehicle, Filter(Vehicle, RentalColumn.Value = "Yes").CombinedNumber);
    ClearCollect(colDriver, Filter(Driver, Department.Value = "B").EmployeeID);
    ClearCollect(colCombinedList, Filter(CombinedList, CombinedNumber in colVehicle));
    ClearCollect(colResult, Filter(colCombinedList, EmployeeID in colDriver));
    
    Label - Text property:
    CountRows(colResult)

     

     

    It works fine.

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 392 Most Valuable Professional

#2
11manish Profile Picture

11manish 181 Super User 2026 Season 2

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 112 Super User 2026 Season 2

Last 30 days Overall leaderboard