SOLVED

Add-PnPDocumentSet creates a regular folder, but no document set?

%3CLINGO-SUB%20id%3D%22lingo-sub-173951%22%20slang%3D%22en-US%22%3EAdd-PnPDocumentSet%20creates%20a%20regular%20folder%2C%20but%20no%20document%20set%3F%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-173951%22%20slang%3D%22en-US%22%3E%3CP%3EHey%20there%3C%2FP%3E%0A%3CP%3EI'm%20new%20with%26nbsp%3Bpnp%20and%20I'm%20quite%20inexperienced%2C%20but%20I'd%20like%20to%20add%20a%20new%20document%20set%20in%20a%20library%20with%20the%20following%20pnp%20command.%3C%2FP%3E%0A%3CP%3EI%20can%20see%20that%20the%20content-type%20I%20define%20(in%20this%20example%20%22Test%20Document%20Set%22)%20is%20being%20created%20-%20which%20is%20a%20document%20set.%20However%2C%20it%20is%20only%20creating%20a%20normal%20folder%20-%20not%20a%20document%20set.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CPRE%3E%3CCODE%20class%3D%22lang-powershell%22%3E%3CSPAN%20class%3D%22hljs-pscommand%22%3EAdd-PnPDocumentSet%3C%2FSPAN%3E%3CSPAN%20class%3D%22hljs-parameter%22%3E%20-List%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%22Documents%22%3C%2FSPAN%3E%3CSPAN%20class%3D%22hljs-parameter%22%3E%20-ContentType%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%22Test%20Document%20Set%22%3C%2FSPAN%3E%3CSPAN%20class%3D%22hljs-parameter%22%3E%20-Name%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%22Test%22%3C%2FSPAN%3E%3C%2FCODE%3E%3C%2FPRE%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EAny%20ideas%20why%3F%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-173971%22%20slang%3D%22en-US%22%3ERe%3A%20Add-PnPDocumentSet%20creates%20a%20regular%20folder%2C%20but%20no%20document%20set%3F%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-173971%22%20slang%3D%22en-US%22%3E%3CP%3EOh%2C%20thanks%20so%20so%20much%20for%20the%20update!%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-173969%22%20slang%3D%22en-US%22%3ERe%3A%20Add-PnPDocumentSet%20creates%20a%20regular%20folder%2C%20but%20no%20document%20set%3F%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-173969%22%20slang%3D%22en-US%22%3E%3CP%3EThis%20is%20a%20known%20issue%20related%20to%20Modern%20View%2C%20see%20the%20issue%20in%20PnP-PowerShell%20GitHub%20repository%3A%3C%2FP%3E%0A%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fgithub.com%2FSharePoint%2FPnP-PowerShell%2Fissues%2F644%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fgithub.com%2FSharePoint%2FPnP-PowerShell%2Fissues%2F644%3C%2FA%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E
Highlighted
New Contributor

Hey there

I'm new with pnp and I'm quite inexperienced, but I'd like to add a new document set in a library with the following pnp command.

I can see that the content-type I define (in this example "Test Document Set") is being created - which is a document set. However, it is only creating a normal folder - not a document set.

 

Add-PnPDocumentSet -List "Documents" -ContentType "Test Document Set" -Name "Test"

 

Any ideas why?

2 Replies
Highlighted
Solution

This is a known issue related to Modern View, see the issue in PnP-PowerShell GitHub repository:

https://github.com/SharePoint/PnP-PowerShell/issues/644

 

 

Highlighted

Oh, thanks so so much for the update!