< Back
Update-D365CeODataEntity
Post
NAME Update-D365CeODataEntity
SYNOPSIS
Update a Data Entity in Dynamics 365 Customer Engagement
SYNTAX
Update-D365CeODataEntity [-EntityName] <String> [-Key] <String> [-Payload] <String> [[-Tenant] <String>] [[-URL]
<String>] [[-ClientId] <String>] [[-ClientSecret] <String>] [-EnableException] [<CommonParameters>]
DESCRIPTION
Updates a Data Entity, defined as a json payload, using the OData endpoint of the Dynamics 365 Customer Engagement
platform
PARAMETERS
-EntityName <String>
Name of the Data Entity you want to work against
The parameter is Case Sensitive, because the OData endpoint in D365CE is Case Sensitive
Remember that most Data Entities in a D365CE environment is named by its singular name, but most be retrieve
using the plural name
E.g. The account Data Entity is named "account", but can only be retrieving using "accounts"
Use the XRMToolBox (https://www.xrmtoolbox.com) to help you identify the names of the Data Entities that you
are looking for
Required? true
Position? 1
Default value
Accept pipeline input? false
Accept wildcard characters? false
-Key <String>
The key that will select the desired Data Entity uniquely across the OData endpoint
The key would most likely be made up from multiple values, but can also be a single value
Required? true
Position? 2
Default value
Accept pipeline input? false
Accept wildcard characters? false
-Payload <String>
The entire string contain the json object that you want to import into the D365CE environment
Remember that json is text based and can use either single quotes (') or double quotes (") as the text
qualifier, so you might need to escape the different quotes in your payload before passing it in
Required? true
Position? 3
Default value
Accept pipeline input? false
Accept wildcard characters? false
-Tenant <String>
Azure Active Directory (AAD) tenant id (Guid) that the D365CE environment is connected to, that you want to
access through OData
Required? false
Position? 4
Default value $Script:ODataTenant
Accept pipeline input? false
Accept wildcard characters? false
-URL <String>
URL / URI for the D365CE environment you want to access through OData
Required? false
Position? 5
Default value $Script:ODataUrl
Accept pipeline input? false
Accept wildcard characters? false
-ClientId <String>
The ClientId obtained from the Azure Portal when you created a Registered Application
Required? false
Position? 6
Default value $Script:ODataClientId
Accept pipeline input? false
Accept wildcard characters? false
-ClientSecret <String>
The ClientSecret obtained from the Azure Portal when you created a Registered Application
Required? false
Position? 7
Default value $Script:ODataClientSecret
Accept pipeline input? false
Accept wildcard characters? false
-EnableException [<SwitchParameter>]
This parameters disables user-friendly warnings and enables the throwing of exceptions
This is less user friendly, but allows catching exceptions in calling scripts
Required? false
Position? named
Default value False
Accept pipeline input? false
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
OUTPUTS
NOTES
Tags: OData, Data, Entity, Update, Upload
Author: M????tz Jensen (@Splaxi)
-------------------------- EXAMPLE 1 --------------------------
PS C:\\>Update-D365CeODataEntity -EntityName "accounts" -Key "accountid=4b306dc7-ab04-4ddf-b18d-d75ffa2dba2c"
-Payload '{"address2_city": "Chicago"}'
This will update a Data Entity in Dynamics 365 Customer Engagement using the OData endpoint.
The EntityName used for the import is "accounts".
It will use the "accountid=4b306dc7-ab04-4ddf-b18d-d75ffa2dba2c" as key to identify the unique Account record.
The Payload is a valid json string, containing the needed properties that we want to update.
It will use the default OData configuration details that are stored in the configuration store.
-------------------------- EXAMPLE 2 --------------------------
PS C:\\>$Payload = '{"address2_city": "Chicago"}'
PS C:\\> Update-D365CeODataEntity -EntityName "accounts" -Key "accountid=4b306dc7-ab04-4ddf-b18d-d75ffa2dba2c"
-Payload $Payload
This will update a Data Entity in Dynamics 365 Customer Engagement using the OData endpoint.
First the desired json data is put into the $Payload variable.
The EntityName used for the import is "accounts".
It will use the "accountid=4b306dc7-ab04-4ddf-b18d-d75ffa2dba2c" as key to identify the unique Account record.
The $Payload variable is passed to the cmdlet.
It will use the default OData configuration details that are stored in the configuration store.
RELATED LINKS
Add-D365CeODataConfig
Get-D365CeActiveODataConfig
Set-D365CeActiveODataConfig
SYNOPSIS
Update a Data Entity in Dynamics 365 Customer Engagement
SYNTAX
Update-D365CeODataEntity [-EntityName] <String> [-Key] <String> [-Payload] <String> [[-Tenant] <String>] [[-URL]
<String>] [[-ClientId] <String>] [[-ClientSecret] <String>] [-EnableException] [<CommonParameters>]
DESCRIPTION
Updates a Data Entity, defined as a json payload, using the OData endpoint of the Dynamics 365 Customer Engagement
platform
PARAMETERS
-EntityName <String>
Name of the Data Entity you want to work against
The parameter is Case Sensitive, because the OData endpoint in D365CE is Case Sensitive
Remember that most Data Entities in a D365CE environment is named by its singular name, but most be retrieve
using the plural name
E.g. The account Data Entity is named "account", but can only be retrieving using "accounts"
Use the XRMToolBox (https://www.xrmtoolbox.com) to help you identify the names of the Data Entities that you
are looking for
Required? true
Position? 1
Default value
Accept pipeline input? false
Accept wildcard characters? false
-Key <String>
The key that will select the desired Data Entity uniquely across the OData endpoint
The key would most likely be made up from multiple values, but can also be a single value
Required? true
Position? 2
Default value
Accept pipeline input? false
Accept wildcard characters? false
-Payload <String>
The entire string contain the json object that you want to import into the D365CE environment
Remember that json is text based and can use either single quotes (') or double quotes (") as the text
qualifier, so you might need to escape the different quotes in your payload before passing it in
Required? true
Position? 3
Default value
Accept pipeline input? false
Accept wildcard characters? false
-Tenant <String>
Azure Active Directory (AAD) tenant id (Guid) that the D365CE environment is connected to, that you want to
access through OData
Required? false
Position? 4
Default value $Script:ODataTenant
Accept pipeline input? false
Accept wildcard characters? false
-URL <String>
URL / URI for the D365CE environment you want to access through OData
Required? false
Position? 5
Default value $Script:ODataUrl
Accept pipeline input? false
Accept wildcard characters? false
-ClientId <String>
The ClientId obtained from the Azure Portal when you created a Registered Application
Required? false
Position? 6
Default value $Script:ODataClientId
Accept pipeline input? false
Accept wildcard characters? false
-ClientSecret <String>
The ClientSecret obtained from the Azure Portal when you created a Registered Application
Required? false
Position? 7
Default value $Script:ODataClientSecret
Accept pipeline input? false
Accept wildcard characters? false
-EnableException [<SwitchParameter>]
This parameters disables user-friendly warnings and enables the throwing of exceptions
This is less user friendly, but allows catching exceptions in calling scripts
Required? false
Position? named
Default value False
Accept pipeline input? false
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
OUTPUTS
NOTES
Tags: OData, Data, Entity, Update, Upload
Author: M????tz Jensen (@Splaxi)
-------------------------- EXAMPLE 1 --------------------------
PS C:\\>Update-D365CeODataEntity -EntityName "accounts" -Key "accountid=4b306dc7-ab04-4ddf-b18d-d75ffa2dba2c"
-Payload '{"address2_city": "Chicago"}'
This will update a Data Entity in Dynamics 365 Customer Engagement using the OData endpoint.
The EntityName used for the import is "accounts".
It will use the "accountid=4b306dc7-ab04-4ddf-b18d-d75ffa2dba2c" as key to identify the unique Account record.
The Payload is a valid json string, containing the needed properties that we want to update.
It will use the default OData configuration details that are stored in the configuration store.
-------------------------- EXAMPLE 2 --------------------------
PS C:\\>$Payload = '{"address2_city": "Chicago"}'
PS C:\\> Update-D365CeODataEntity -EntityName "accounts" -Key "accountid=4b306dc7-ab04-4ddf-b18d-d75ffa2dba2c"
-Payload $Payload
This will update a Data Entity in Dynamics 365 Customer Engagement using the OData endpoint.
First the desired json data is put into the $Payload variable.
The EntityName used for the import is "accounts".
It will use the "accountid=4b306dc7-ab04-4ddf-b18d-d75ffa2dba2c" as key to identify the unique Account record.
The $Payload variable is passed to the cmdlet.
It will use the default OData configuration details that are stored in the configuration store.
RELATED LINKS
Add-D365CeODataConfig
Get-D365CeActiveODataConfig
Set-D365CeActiveODataConfig