Last month, one of our SharePoint Consultants was asked to export some lists from SharePoint 2010 into SharePoint 2013. We thought other SharePoint Administrators might be interested in this method, which uses PowerShell to complete the task. In the image below you can see the company list to be exported from SharePoint 2010:
First, SharePoint Administers should open a PowerShell Console and enter the following cmdlet (For those new to PowerShell, a ‘cmdlet’ is a lightweight command that is used in the Windows PowerShell environment):
Export-SPWeb http://www.contoso.com –Path c:\Company.cmp –ItemUrl “/Lists/Company” –Verbose
You can see in the screengrab above that the cmdlet generated the ‘Company.cmp’ file. Next we need to rename the file to use as a compressed cabinet file (file_name.cab). For this example, we’re going to use the file name ‘Company.cab’ – you can do this in a Command Prompt Console by entering the following:
C:\>ren Company.cmp Company.cab
With that complete, expand the ‘Company.cab’ file with the tool of your choice, and then edit the SystemData.xml file with a Text Editor Tool.
You need to change some values in Version and Build from ‘14’ to ‘15’.
If you’ve done this correctly you should now see results similar to those seen in the image below:
Your next step is to create a new Company.cab file. For this process, our SharePoint Consultants suggest using the IZArc Tool, which you can download freely by clicking on this link: http://www.izarc.org/
Next you’ll need to select all of the files which you had expanded previously, as seen in the image below:
Now once again, rename the file in your Command Prompt Console with this command:
C:\>ren Company.cab Company.cmp
Copy the Company.cab file to your SharePoint Server destination, open a PowerShell console and now run the next cmdlet to import the Company List to SharePoint 2013:
When the imported process has been completed, go to your SharePoint 2013 site and you will now see a new list in the Site Contents.
Click on ‘Company List’ to display all the items.
Let us know how this process works for you, or if you have an alternate method that you wish to share, please do so in the comments section below. We’d love to get your input.