Getting started
Qualitem Metadata Checker Report Tool Overview
The Metadata Checker Report Tool is a command line utility that can be used to scan Microsoft Office Documents in your SharePoint Online site for issues such as broken quick parts or invalid managed metadata. It is capable of scanning an entire site collection, a single web, a list or specific files. The scan results are displayed on screen and written to a CSV report. Any invalid documents detected by the report can be fixed using the ‘Qualitem Metadata Checker Repair Tool’.
Getting Started
1. Extract the files from the QualitemMetadataCheckerReport.zip file to your PC.
2. Open a command prompt at that location.
3. Run the command Qualitem.MetadataChecker.Report.Cli.exe, you should see a screen as below:
4. Type in the URL of your SharePoint site – this can be a site collection URL or the URL of a subsite / web within a site collection. For example https://mycompany.sharepoint.com or https://mycompany.sharepoint.com/sites/my-site-collection/my-subsite
5. You will be redirected to sign in with your Microsoft account.
6. After logging in you can specify the scan mode:
- S – scans your entire site collection (or a subsite), including all sub sites (recursively).
- W – scans all document libraries in a single web (does not scan recursively).
- L – scans all documents in a single list.
Note that if you want to scan a single file, you will need to launch the app specifying the –filter option (see below for a detailed description of all available command line switches).
7. If you specified “L” to scan a list, you will be prompted to enter the title of the list.
8. The scan will run. After the scan has finished you will see a CSV file in the output directory. The file name includes the date as a timestamp, for example Report_2020-01-01-133000.csv. Details of any invalid documents will be listed in the report.
Command Line Switches
The Report Tool can also be run with a number of command line switches / parameters. When using command line switches, if any required values are not specified, the user will be prompted for those values. For example, you could specify the site URL as a switch but would then be prompted for credentials. A list of command line switches is shown below:
Short Name | Full Name | Description |
s | site | URL of site collection or subsite. |
m | mode | Scan mode: s for site, w for web, l for list or r for report. |
l | list | Title of list. |
F | filter | File name filter. Note that currently dashes are not supported as part of the file name. You can use a JSON file to input file names to work around this (see below). |
u | user | Login user name. |
P | password | Login password. |
n/a | reportfile | Name of file containing JSON report data. |
Usage Examples
- Perform a site scan specifying all parameters (app runs silently without needing interaction):
Qualitem.MetadataChecker.Report.exe -s https://company.sharepoint.com -m s -u user@company.onmicrosoft.com -p passwordhere
- Perform a list scan in a subsite specifying all parameters except credentials (user will be prompted):
Qualitem.MetadataChecker.Report.exe -s https://company.sharepoint.com/sites/site-name/subsite -m l -l ListTitle
- Specify a file name filter to scan files with the term “Expense-Report-2020” in the file name:
Qualitem.MetadataChecker.Report.exe -s https://company.sharepoint.com -m s –filter “Expense-Report-2020”
- Specify a file name filter to scan all docx files in the site:
Qualitem.MetadataChecker.Report.exe -s https://company.sharepoint.com -m s –filter “.docx”
JSON File Format
The Metadata Checker Report Tool can accept a JSON file as input to specify the list of files it should process. An example of the file format is shown below:
[
{
"ServerRelativeUrl": "/shared documents/my-file.docx",
"Status": 1,
},
{
"ServerRelativeUrl": "/moredocuments/another-file.docx ",
"Status": 1,
}
]
The file can be processed using the reportfile switch (note that two dashes are needed before the “reportfile” switch):
Qualitem.MetadataChecker.Report.exe -s “https://company.sharepoint.com ” -m r –reportfile “my-report.json”