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 / Load items from sharep...
Power Apps
Answered

Load items from sharepoint but select specific columns

(0) ShareShare
ReportReport
Posted on by

I am having some issues with performance when loading Sharepoint items in my PowerApp. The main reason is that one of the Sharepoint columns contains a large base64 encoded image, so the response body is quite large. It takes over a minute for items to appear in the gallery in my PowerApp.  

Is it possible to Collect the sharepoint list & filter the specific columns ?

I tried  //ClearCollec(colName,ShowColumns(myDataSource,"Column1","Column2")) but it doesn't works since it seems to collect THEN filter columns.

 

Thanks !

 

Categories:
I have the same question (0)
  • AaronKnox Profile Picture
    514 Super User 2024 Season 1 on at

    Hi @ProFe ,

    My guess is ClearCollect() is slowing you down.  That will instruct Power Apps to load all records in the collection, 500 up to 2000 depending on your settings.  I'd try it with just the ShowColumns(), although that doesn't delegate to SharePoint:

    ShowColumns(myDataSource,"Column1","Column2")

     

    A better option might be to just have your data source as the gallery items formula:

    myDataSource

     

    Hope this helps!

    Aaron

  • ProFe Profile Picture
    on at

    Hi @AaronKnox ,

     

    Thank you for your answer, I tried both of your solutions but I still encounter a long Duration when I call my data from sharepoint. I tried to LastN(ShowColumns(MyDataSource,"Column1","Column2"),10) and nothing changed.

    I suppose that powerapps retrieve every items, then display the selected columns or the LastN items. Therefore, I always call my base64 image for every item...

    A solution would be to transfer my base64 image (multiline text column) to attachment field with power automate, but it involves some other apps modifications.

  • Verified answer
    AaronKnox Profile Picture
    514 Super User 2024 Season 1 on at

    Hi @ProFe ,

    A gallery with just myDataSource in the gallery.items property will only fetch the first 100 records until you start scrolling.  If that is still slowing you down then consider adding a filter to get this down to 10-20 records.  Depending on your data source, you may be able to get away with something simple like just showing records created within the past week:

    Filter(myDataSource, Created > DateAdd(Today(),-7) )

     

    Hope this helps!

    Aaron

     

  • ProFe Profile Picture
    on at

    I tried your solution, it kinda works for max 50 items and then starts struggling. It should be enough for the moment, but I'm still curious if there is a way to remove a column when the call to my DataSource is made.

     

    Thanks

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

Last 30 days Overall leaderboard