Troubleshoot New-MigrationBatch AllowUnknownColumnsInCsv in Exchange Online
Question details
The user needs to understand why AllowUnknownColumnsInCsv does not behave as expected when creating an Exchange Online migration batch.

- Product
- Exchange Online PowerShell
- Device & OS
- not provided
- Scenario
- Creating a migration batch from a CSV file using New-MigrationBatch.
- Observed behavior
- AllowUnknownColumnsInCsv remains false with a single-column CSV, a multi-column CSV produces an error, and Set-MigrationBatch does not change the value.
Connect to Exchange Online PowerShell and identify the migration type and CSV file used for the batch. Have the exact command and error message available, with any credentials or personal information removed before sharing them.
Check the Migration CSV and Supported PowerShell Parameters
Use this check to rule out unsupported parameters or unexpected CSV headers before investigating the reported behavior further.
In the connected PowerShell session, run Get-Command New-MigrationBatch -Syntax and Get-Command Set-MigrationBatch -Syntax. Check whether AllowUnknownColumnsInCsv is listed for the command and parameter set you are using.
Run Get-Content -Path 'C:\path\migration.csv' -TotalCount 1, replacing the path with your CSV file. Compare the column names with the CSV requirements for your migration type in Microsoft's New-MigrationBatch documentation.
In your CSV editor, create a test file containing the required and recognized columns for your migration type, then run New-MigrationBatch with that file. Do not remove columns required by the migration type.
If your command uses BadItemLimit or LargeItemLimit, review their documentation and use recommended values, typically 10 or lower where applicable. Changing these limits is not a confirmed fix for AllowUnknownColumnsInCsv.

Report Persistent Parameter Behavior to Microsoft
Use Microsoft support or the migration community if the parameter still behaves unexpectedly after the CSV and command checks.
Review Migration CSV Files with WPS Spreadsheets
WPS Office is a free, lightweight Office alternative with a familiar interface for reviewing spreadsheet data and CSV columns. Its Microsoft Office format compatibility makes moving everyday files straightforward, although it cannot fix Exchange Online PowerShell parameters.

Frequently Asked Questions
Why does AllowUnknownColumnsInCsv remain false?
The cause is not established by the reported behavior. Check the New-MigrationBatch syntax and CSV requirements for your migration type, then contact Microsoft support if the value still appears incorrect.
Can Set-MigrationBatch change AllowUnknownColumnsInCsv?
Check Get-Command Set-MigrationBatch -Syntax in your connected session to see which parameters are supported. In the reported case, Set-MigrationBatch did not change the value.
Which columns should my migration CSV contain?
The required and recognized columns depend on the migration type. Compare your header with the relevant CSV requirements in Microsoft's New-MigrationBatch documentation before removing or renaming columns.
Will lowering BadItemLimit or LargeItemLimit fix the CSV error?
Not necessarily. Review Microsoft's guidance for the migration type and keep these values at recommended levels, typically 10 or lower where applicable, but do not treat that change as a confirmed fix for the CSV parameter.




