SharePoint Online - Large List | REST API Issue

Copper Contributor

Hi,

 

I have a list which has around 28K items. We have a dashboard displaying data from this list. By default, we are fetching data for the past 120 days, and it perfectly worked fine. 

 

Today, we have around 13K items created on the same list by mistake. Now the dashboard is not working and it is giving this error "The attempted operation is prohibited because it exceeds the list view threshold".

 

The following steps are taken as of now.

  1. deleted 13k items from the process list
  2. deleted from the recycle bin ( primary and secondary)

I'm still facing the same error.

 

Can you please let me know if anyone has come across this kind of issue & let me know any solution?

 

Thanks in advance.

1 Reply

@JND 

 

What is the REST API end point you are using? What are the filters you are using in the API call? Are you using $top to in your API call?

 

Make sure your one API call returns less than 5000 records after adding filtering conditions.

 

Try adding indexing on list columns you are using for filtering/sorting in your API call. Follow: Add an index to a SharePoint list or library column 


Please click Mark as Best Response & Like if my post helped you to solve your issue. This will help others to find the correct solution easily. It also closes the item. If the post was useful in other ways, please consider giving it Like.