Update-Odoo Cmdlet
Updates Odoo data.
Syntax
Update-Odoo [parameters]
Remarks
The Update-Odoo cmdlet allows you to use a syntax similar to SQL UPDATE statements to update Odoo data.
$conn = Connect-Odoo -User 'MyUser' -APIToken 'MyToken' -URL 'https://MyOdooSite/' -Database 'MyDatabase' Update-Odoo -Connection $conn -Table "res_users" -Columns @("email") -Values @("[email protected]") -Id "12"The Where parameter can also be used to specify the primary key of the table:
Update-Odoo -Connection $conn -Table "res_users" -Columns @("email") -Values @("[email protected]") -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.'" | Update-Odoo -Columns @("company_name") -Values @("Company Inc. 2")