Forum Discussion
Gurdev Singh
Jul 18, 2023Iron Contributor
Deleting a large SharePoint library with retention labels applied to content
Are there any clever methods known to anyone for deleting a large SharePoint library that has retention label applied to all its content? I understand we will have to individually delete each item to...
Gurdev Singh
Jul 20, 2023Iron Contributor
Adding more details...We ultimately decided to use the retention and disposal labels to accomplish this. Given the root cause behind library unable to be deleted is a long term retention label, deleting items using script was moving these to PreservationHoldLibrary where these will remain for a very long time.
As the data is duplicate and redundant, we have decided to create a new retention label to delete content after 2 days from creation date. This label will be applied to all items in library, making the built-in SharePoint function to then get rid of it for us.
Barbarur
Jul 21, 2023Copper Contributor
Deleting the Retention Label and the Policy used to publish it would have remove the label from every single file automatically. Then you could delete the library.