Thursday, March 17, 2016

Import subsite and Site Collection in SharePoint power shell script

Import the subsite

STSADM:

stsadm -o import -url "http://sharepointsite/sites/order/" -filename D:\backup.cmp -includeusersecurity -versions 4

Powershell:

Add-pssnapin microsoft.sharepoint.powershell

Export-SPWeb -identity "http://sharepointsite/sites/order/"  -path D:\backup.cmp -includeusersecurity  -force

No comments:

Post a Comment