Cmdlets for Odoo

Build 24.0.9060

Remove-Odoo Cmdlet

Parameters   Output Objects  

Deletes Odoo data.

Syntax

Remove-Odoo [parameters]

Remarks

The Remove-Odoo cmdlet allows you to use a syntax similar to SQL DELETE statements to delete Odoo data.

$conn = Connect-Odoo -User 'MyUser' -APIToken 'MyToken' -URL 'https://MyOdooSite/' -Database 'MyDatabase'
Remove-Odoo -Connection $conn -Table "res_users" -Id "12"
The Where parameter can also be used to specify the primary key:
Remove-Odoo -Connection $conn -Table "exTablePowershell;" -Where "id = 12"
The primary key can also be passed to the cmdlet along the pipeline:
Select-Odoo -Connection $conn -Table res_users -Where "company_name = 'Company Inc.'" | Remove-Odoo

Copyright (c) 2024 CData Software, Inc. - All rights reserved.
Build 24.0.9060