Create an entity with related entities

In our earlier post we took a look at how to Create an entity with simple data types using MS Dynamics CRM Web API. Today we will create an entity with related entities. We will create the ‘primarycontact’ along with the ‘account’ record. We will also be creating an opportunity for the ‘account’ and related ‘task’ with the ‘opportunity’. Please note that for ‘lookup’, we use ‘odata.bind’ expression, but for related ‘contact’ we don’t use the ‘odata.bind’ expression. Also note the difference between single valued and collection valued properties, and multi values initialization and push functions both can be used for collection valued properties.

And here is how to do it in Jquery.

For more help related to MS Dynamics CRM, Please Contact Us.

Leave a Comments

 

Your email is safe with us.
*
*