Remove-MicrosoftProject Cmdlet
Deletes Microsoft Project data.
Syntax
Remove-MicrosoftProject [parameters]
Remarks
The Remove-MicrosoftProject cmdlet allows you to use a syntax similar to SQL DELETE statements to delete Microsoft Project data.
$conn = Connect-MicrosoftProject -User 'myuseraccount' -Password 'mypassword' -URL 'http://myserver/myOrgRoot' Remove-MicrosoftProject -Connection $conn -Table "Projects" -Id "11111111-c6be-e111-1f1e-00155d055681"The Where parameter can also be used to specify the primary key:
Remove-MicrosoftProject -Connection $conn -Table "exTablePowershell;" -Where "Id = 11111111-c6be-e111-1f1e-00155d055681"The primary key can also be passed to the cmdlet along the pipeline:
Select-MicrosoftProject -Connection $conn -Table Projects -Where "Name = 'Tax Checker'" | Remove-MicrosoftProject