Forum Discussion
santnerin
Sep 16, 2025Copper Contributor
Trouble adding and indexing a new column to a large SharePoint document library (threshold 5000)
I need assistance adding a new column to a SharePoint document library. The library contains more than 5,000 items, and when I attempt to create the column via the Microsoft Graph API I receive an error stating that the list view threshold of 5,000 has been exceeded.
Oddly, when this error occurs the column still appears in the library, but it is not indexed. Any attempt to update the column definition to set indexed = true fails for the same threshold reason.
Is there an alternative way to create and index this column programmatically? Manually adding the index through the SharePoint UI works, but that is not feasible for our use case — we need a repeatable, automated solution that can be applied across many customers.
Thanks.
No RepliesBe the first to reply