Remove-CSV Cmdlet
Deletes CSV data.
Syntax
Remove-CSV [parameters]
Remarks
The Remove-CSV cmdlet allows you to use a syntax similar to SQL DELETE statements to delete CSV data.
$conn = Connect-CSV -Location 'C:\MyCSV' -URI 'token' Remove-CSV -Connection $conn -Table "NorthwindOData" -Id "1"The Where parameter can also be used to specify the primary key:
Remove-CSV -Connection $conn -Table "exTablePowershell;" -Where "Id = 1"The primary key can also be passed to the cmdlet along the pipeline:
Select-CSV -Connection $conn -Table NorthwindOData -Where "Email = '[email protected]'" | Remove-CSV