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 filter last 30 ...
Power Apps
Answered

How to filter last 30 entries in a gallery in a PowerApps?

(0) ShareShare
ReportReport
Posted on by 121

Hello Team,

Could anyone help to filter a Gallery with last 30 entries from the current date?

Categories:
  • Verified answer
    Prabhakar_S Profile Picture
    735 Moderator on at

    Hi @Nisha_Innola ,

     

    Assuming you are using SharePoint as a data source. Try this,

     

    SortByColumns(
    FirstN(
    Filter(
    YourSharePointList, // Replace YourSharePointList with the actual name of your SharePoint list
    DateColumn <= Today()
    ),
    30
    ),
    "Created",
    SortOrder.Descending
    )

     

    Thanks!!!

     

    Please consider marking my response as the accepted solution if it successfully resolves your concern. If you found the information beneficial in other aspects, kindly express your appreciation by giving it a thumbs-up.

  • Nisha_Innola Profile Picture
    121 on at

    Hello @Prabhakar_S ,

    Thank you so much for your reply. It worked and the gallery filtered out 30 entries . But the filtered results are different as i m using collection along with the filters. Does that affect the result?

     

    ClearCollect(collection name, SortByColumns(FirstN(Filter(Sharepoint name,User = Username And Created <= Today()),30),"Created",SortOrder.Descending));

     

    I want the result from current date to 30 entries. But my gallery showed entries in the month of September with two days only. But I have data till current date.

    Can you help me out with this please?

     

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

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 342 Super User 2026 Season 2

#2
M Bilal Khan Profile Picture

M Bilal Khan 271

#3
Mohsin Ali Profile Picture

Mohsin Ali 239

Last 30 days Overall leaderboard