{"id":1258,"date":"2020-11-09T21:43:55","date_gmt":"2020-11-09T21:43:55","guid":{"rendered":"http:\/\/www.kofrimpong.com\/?p=1258"},"modified":"2024-01-26T09:50:13","modified_gmt":"2024-01-26T09:50:13","slug":"export-and-import-sharepoint-document-list-schema","status":"publish","type":"post","link":"https:\/\/www.kofrimpong.com\/export-and-import-sharepoint-document-list-schema\/","title":{"rendered":"Export and Import SharePoint Document & List Schema"},"content":{"rendered":"\n
Using the new PnP provisioning engine, you can export the schema for an existing document library or list, then import it in a new environment.<\/p>\n\n\n\n
Here is the code using SharePoint PnP powershell.<\/p>\n\n\n\n
Connect-PnPOnline \"https:\/\/yourtenant.sharepoint.com\/sites\/yoursite\" -UseWebLogin\nExport-PnPListToProvisioningTemplate -List \"Documents\" -Out template.xml\n\n#connect to new environment or site\nApply-PnPProvisioningTemplate -Path template.xml\n<\/code><\/pre>\n\n\n\nUpdate<\/i><\/a><\/h4>\n\n\n\nThese commands have been renamed to<\/p>\n\n\n\n
Export-PnPListToSiteTemplate
Invoke-PnPSiteTemplate<\/code><\/pre>\n","protected":false},"excerpt":{"rendered":"Using the new PnP provisioning engine, you can export the schema for an existing document library or list, then import it in a new environment.<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_coblocks_attr":"","_coblocks_dimensions":"","_coblocks_responsive_height":"","_coblocks_accordion_ie_support":"","_wp_applaud_exclude":false,"footnotes":""},"categories":[10],"tags":[56],"series":[],"yoast_head":"\n
Export and Import SharePoint Document & List Schema<\/title>\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\t\n\t\n\t\n