Sunday, 6 November 2016

Download Content using filter on a given Column

Today I am providing the Power Shell Script that will download all the Documents of the given Library of given Site on the bases of filter on a given Metadata column. It is useful if you want to take backup of documents of SharePoint on the bases of some filter of Taxonomy column. Folder structure will be the same as in SharePoint and Site url will be converted as folder to identify the sites.

Script will accept the reports file path where it will create the folder and download the files there -

Inputs - Following are the Input for the script.

Web site - Url of the site where library exists
Library title - Title of the library that you want to download
File path - Path the files where script will download all the files.
Column - Internal name of the column where you want filter
Value - Value to be filtered

Outputs - 
Items of of the list will be downloaded under the name of the list folder

Dependencies -
For executing this script user must be added in site collection administrators in all the sites.
User should have Shell Admin rights to run the scripts.
Run Management Shell as an Administrator. 
How to execute -
Copy this script and paste in Note pad.
Save this file as .ps1.
Run this script in SharePoint Management Shell.
Follow on screen instructions.


Go to above link to get the script.

No comments:

Post a Comment