cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
jblomberg
Helper II
Helper II

Create collection with data from one SharePoint list to filter another list

I got a SharePoint list that has information about courses employees can follow and another list in which the courses that people signed up for are registered. I wanna do something pretty basic, but I'm kinda blacked-out, lol. Help is appreciated!

 

In the registration list the user's email, name, the code of the course and the date it'll take place is stored. I filter this list and create a collection with only the records relevant to the current user (by filtering the EmailCursist column).

 

Inschrijvingen.png

 

What I need is another collection that only shows the record from the list with course information that the current user signed up for. The list with course information has a lot of columns, but the picture below shows the relevant ones for this question, which is the Title column.

 

Cursusaanbod.png

 

As you can see, the Title column from this list corresponds with the Cursuscode column from the first list. So it should be easy to create a collection that collects only the records from the list with course information, based on the courses the user signed up for.

 

Any help is greatly appreciated!

 

- Joeri Blomberg

1 REPLY 1
Drrickryp
Super User
Super User

@jblomberg 

Starting with your second list, assuming it is called Courses, and assuming the first list is called RegistrationList, and there is a Dropdown1 with the RegistrationList as its items property and a gallery with its Items property

 

With({wCourses:
               AddColumns(
                          Courses, "Enrollee", Lookup(
                                                        Registrationlist, CursusCode = Title, Titel
                                               )
               )
     },
      Filter(
             wCourses, Enrollee = Dropdown1.Selected.Value
      )
)

 

Selecting the enrollee in the dropdown should populate the gallery with their courses and there is no need for a collection. 

 

Helpful resources

Announcements
Power Apps News & Annoucements carousel

Power Apps News & Announcements

Keep up to date with current events and community announcements in the Power Apps community.

Microsoft 365 Conference – December 6-8, 2022

Microsoft 365 Conference – December 6-8, 2022

Join us in Las Vegas to experience community, incredible learning opportunities, and connections that will help grow skills, know-how, and more.

Power Apps Community Blog Carousel

Power Apps Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Top Kudoed Authors
Users online (3,149)