It doesn’t seem there is a built-in way in MOSS/WSS to delete all list items from a list without deleting the entire list. A workaround is to save the list a a template without content, delete the list and recreate it using the template.
However, there is a gl-deletelistitem option in STSADM Custom Extentions that can be used. It works well but it is rather slow so for large lists the template method may still be faster.
Here's an example of how to delete a list passing in the force parameter:
stsadm –o gl-deletelist -url "http://intranet/Documents/Forms/AllItems.aspx" -force
If you receive error Exception from HRESULT 0x81070215 when you open a list or access the SharePoint site manager, a list has not properly been deleted and is in a corrupted state. You can change the corresponding custom list definition after you have deleted the list to fix the problem. Because the SharePoint pages don’t allow you to delete the list, you have to use the STSADM program’s forcedeletelist operation.
Although the help message displays information about using the forcedeleteweb operation, you have to use forcedeletelist instead. The syntax is:
stsadm.exe -o forcedeletelist -url
However, there is a gl-deletelistitem option in STSADM Custom Extentions that can be used. It works well but it is rather slow so for large lists the template method may still be faster.
Here's an example of how to delete a list passing in the force parameter:
stsadm –o gl-deletelist -url "http://intranet/Documents/Forms/AllItems.aspx" -force
If you receive error Exception from HRESULT 0x81070215 when you open a list or access the SharePoint site manager, a list has not properly been deleted and is in a corrupted state. You can change the corresponding custom list definition after you have deleted the list to fix the problem. Because the SharePoint pages don’t allow you to delete the list, you have to use the STSADM program’s forcedeletelist operation.
Although the help message displays information about using the forcedeleteweb operation, you have to use forcedeletelist instead. The syntax is:
stsadm.exe -o forcedeletelist -url
Comments
Post a Comment