Import Data to SharePoint with the PnP Generator
A kalmstrom.com Tools tutorial
The
free kalmstrom.com service
SharePoint PnP List Generator, creates new SharePoint
lists in a way that follows recommended practices. It is
also convenient to use the generator to import data to SharePoint.
Add all data together with values for the new list's content
type and site columns to the PnP Generator, and it will
create a PowerShell script for the list.
Copy the PowerShell code, paste it in Windows PowerShell
ISE and run it, and the new list is quickly created with
all the data.
- In the kalmstrom.com PnP List Generator, enter the
name of a content type group. It can be a new or an
existing group.
- Enter the URL to the SharePoint site where you want
the new list to be created.
- Enter the name of the new content type you want
to create.
- Enter the name of the new list.
- Under Site Columns, type column names under the
Title cell, or copy and paste them from the existing
data source. Select the column types you wish to use.
- Copy the rest of the data from the source. Select
the first cell under under Title in the PnP Generator
and paste the data. Check that it looks good.
- Click on Copy to Clipboard.
- Run Windows PowerShell ISE as an administrator,
open a new script and paste the PowerShell code you
copied from the PnP Generator.
- Make any changes you prefer in the script.
- Run the script. Now a new list will be created in
the SharePoint site you specified and all data from
the source will be added to the list.
Peter Kalmström, CEO and Systems Designer of kalmstrom.com
Business Solutions, shows the process in the demo below.
Peter uses data from an Excel list, but you of course add
data from any table to the PnP List Generator, even data
from a SharePoint list that you are not satisfied with.
Peter has a Title column in his Excel file. If you don't
have that you can rename the Title field in the PnP Generator
to something that fits the first column in your source.
Then the copy and paste will be quick and give a good result.
|