Cmdlets for Sage 50 UK

Build 23.0.8839

Update-Sage50UK Cmdlet

Parameters   Output Objects  

Updates Sage 50 UK data.

Syntax

Update-Sage50UK [parameters]

Remarks

The Update-Sage50UK cmdlet allows you to use a syntax similar to SQL UPDATE statements to update Sage 50 UK data.

$conn = Connect-Sage50UK -URL 'http://localhost:5493/sdata/accounts50/GCRM/{C4C863BE-B098-4A7D-A78B-D7A92B8ADB59}' -User 'Manager' -Password 'xxxxxx'
Update-Sage50UK -Connection $conn -Table "TradingAccounts" -Columns @("Name") -Values @("Joe Smith") -Id "c2ef66a5-a545-413b-9312-79a53caadbc4"
The Where parameter can also be used to specify the primary key of the table:
Update-Sage50UK -Connection $conn -Table "TradingAccounts" -Columns @("Name") -Values @("Joe Smith") -Where "TradingAccountUUID = 'c2ef66a5-a545-413b-9312-79a53caadbc4'"
The primary key can also be passed to the cmdlet along the pipeline:
Select-Sage50UK -Connection $conn -Table TradingAccounts -Where "TradingAccountUUID = 'c2ef66a5-a545-413b-9312-79a53caadbc4'" | Update-Sage50UK -Columns @("TradingAccountUUID") -Values @("c2ef66a5-a545-413b-9312-79a53caadbc4 2")

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