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 / Search not working pro...
Power Apps
Unanswered

Search not working properly even for 2000 records

(0) ShareShare
ReportReport
Posted on by 603

Hi, 

 

I have 10K items in SharePoint list which is being shown in the gallery using below formula.

 

If(
!IsBlank(TextInput3.Text),
SortByColumns(
Filter(
DataSource,
StartsWith(
BodySingleLineofText,
TextInput3.Text
) Or StartsWith(
AuthorName,
TextInput3.Text
) Or StartsWith(
ArticleYearSLOT,
TextInput3.Text
) Or StartsWith(
AuthorDisplayName,
TextInput3.Text
) Or AuthorName = TextInput3.Text Or ArticleYearSLOT = TextInput3.Text
),
"Date_Posted",
Descending
),
SortByColumns(
DataSource,
"Date_Posted",
Descending
)
)

 

Now I want to implement search functionality which will search by newsfeed description (multiple lines of text) and show me the search results in gallery, order by newsfeed posted date descending. 

 

May I know how to modify the above code to include search by description which will atleast search across 2000 records and show it in chronological order. I tried adding search function in above code but doesn't work properly

 

Iantaylor2050_0-1676201032623.png

 

 

Categories:
  • Drrickryp Profile Picture
    Super User 2024 Season 1 on at

    @Iantaylor2050 

    For 10k items you will need to narrow down the list to 2k first perhaps with the other filters and use a second textinput box for the search. This would require the TextInput3 to not be blank in order to achieve this, as searching >2000 items is not delegatable in SharePoint.  If the _items table is >2000, the users should be warned that the search may be incomplete. 

     

    With({_items: SortByColumns(
     Filter(DataSource,
     Or(
     StartsWith(BodySingleLineofText, TextInput3.Text),
     StartsWith(AuthorName,TextInput3.Text), 
     StartsWith(ArticleYearSLOT,TextInput3.Text),
     StartsWith(AuthorDisplayName,TextInput3.Text),
     AuthorName = TextInput3.Text, 
     ArticleYearSLOT = TextInput3.Text
     )
     ),"Date_Posted",Descending
     )
     },
     Search(_items, TextInput4.Text,"Newsfeed Description"),
     If(
     CountRows(
     _items)=2000,Notify("Searching Newsfeed Description May Be Inaccurate", Error)
     ) 
    )
     
    
    

     

    * you may need to use intellisense for "Newsfeed Description".  FYI: Don't uses spaces or special characters in Sharepoint column names. 

     

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 283

#3
Mohsin Ali Profile Picture

Mohsin Ali 221

Last 30 days Overall leaderboard