Hi @john john Pter ,
When you sort a column within a list view, SharePoint automatically creates an index for that column. This index helps optimize filtering and sorting operations within that view.
The automatic index creation is limited to lists and libraries with fewer than 20,000 items. If your list has more than 20,000 items, you won’t get automatic indexing when sorting within a view.
Unfortunately, automatic indexing doesn’t extend to these scenarios. When you perform sorting or filtering using Power Apps, Power Automate (Flow), REST API, or Graph API, SharePoint won’t automatically create indexes.
If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.