Delete data from sharepoint list

Iron Contributor
I have a SP list with about 40k rows. I need to clean this and delete old rows.

But I can not find an good way to delete large amounts.
I basically can only work with 100-200 posts at a time and it lags very much.

Can I sync it to excel and then update it to SP?

Other solutions?
1 Reply

@Oskar Kuus I believe PowerShell is your savior. You can use it in any way you want to fulfill your needs.

 

Delete a single item: 

https://www.sharepointdiary.com/2016/01/sharepoint-online-delete-list-item-using-powershell.html

 

Delete multiple items:

https://www.sharepointdiary.com/2015/10/delete-all-list-items-in-sharepoint-online-using-powershell.... 

https://social.technet.microsoft.com/wiki/contents/articles/17895.powershell-script-to-delete-items-... 

 

Just a thought - You can create a view based off the certain condition (e.g. SP view for older items), and delete the items manually by selecting all.

 

Hope it helps.