I am using the Microsoft Dynamics Web API to write data to an entity in Microsoft Dynamics 365. When I try to do a deep insert I am receiving the error
An undeclared property 'ccseq_employeeid' which only has property annotations in the payload but no property value was found in the payload. In OData, only declared navigation properties and declared named streams can be represented as properties without values.
Why am I receiving this error and how can I resolve the error?
JSON
{
"ccseq_importdate" : "2017-05-28T04:00:00Z",
"ccseq_month" : "1",
"ccseq_year" : "2017",
"ccseq_name" : "Test",
"ccseq_status" : "100000000", "ccseq_ccseq_expensetransactionset_ccseq_expensetransaction_ExpenseTransactionSetID" :
[
{
"[email protected]": "/systemusers(6d2fd71b-32d1-dd11-a4f5-001a6449bbe7)",
"[email protected]": "/ccseq_clients(663ebd00-73b9-4faf-90ed-f56bb9c2dc9b)",
"ccseq_navemployeeid" : "11111",
"ccseq_employeefirstname" : "John"
}
]
}
ExpenseTransactionSet
is the parent of ExpenseTransaction
meaning that ExpenseTransaction
has a lookup to ExpenseTransactionSet
. ccseq_ccseq_expensetransactionset_ccseq_expensetransaction_ExpenseTransactionSetID
is one to many relationship. systemuser
and ccseq_clients
are separate entities that are lookups in ExpenseTransaction
.
I've also tried the below variations on the "[email protected]"
[email protected]
[email protected]
[email protected]
[email protected] : systemusers()
[email protected]
[email protected]
I have seen this question and this question and tried the suggested resolutions without success.
ccseq_ccseq_expensetransactionset_ccseq_expensetransaction_ExpenseTransactionSetID
has an odata type of#Microsoft.Dynamics.CRM.OneToManyRelationshipMetadata
.ExpenseTransactionSet
is the parent ofExpenseTransaction
which has lookups to separate entities ofsystemuser
andccseq_clients
– Owades