on 12-11-2014 11:18 AM
Hi All,
I was trying to implement create deep entity. And what I did was first did a get for the GET_EXPANDED_ENTITYSET and then used the same as a request. I exactly have one data in the header table and 2 data in the item table 1 and 1 data in the item table 2. So I just used the same to create one more. I am getting a 400 Bad request error. I hope atleast the breakpoint should stop then I can figure out the issue.
My questions?
1. Do we need to pass anything in the header name and value?
2. For doing an update in the deep entity which method should be used ?
Below is the XML that i got as a response from the GET_EXPANDED_ENTITYSET.
*********************
feed xmlns="http://www.w3.org/2005/Atom" xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" xmlns:d="http://schemas.microsoft.com/ado/2007/08/dataservices" xml:base="http://ddadb038.ctr.globedev.ddc:8002/sap/opu/odata/GLB/9GT_GW_PR_MSP_PBCRA_SRV/">
</m:properties>
</content>
</entry>
</feed>
</m:inline>
</link>
</m:properties>
</content>
</entry>
</m:properties>
</content>
</entry>
</feed>
</m:inline>
</link>
</m:properties>
</content>
</entry>
</feed>
**********************************************************
Tags edited by: Jitendra Kansal
Tags edited by: Jitendra Kansal
Hi Koushik,
1. Do we need to pass anything in the header name and value?
I guess below parameters:
X-CSRF-TOKEN : <value returned from GET method>
Content-Type : application/atom+xml;type=entry;charset=utf-8
2. For doing an update in the deep entity which method should be used ?
You have to used POST method.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello Koushik,
1. Please follow the blog specified by Jitendra. You will be able to accomplish Create Deep Operations.
2. You cannot perform Update on Deep Entities.There is no such method available to perform the same like Update_Deep_Entity.
You need to perform normal Update itself ( Update_Entity ) on the item level based on use of appropriate Key
Regards,
Ashwin
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Ashwin,
I have successfully implemented the create. But problem I am facing is when I implement Create Deep Entity then the expand is not working.
I assume this is because for the redefinition of the "Define" method in the create deep entity. Any suggestion how to overcome this.
Regards,
Koushik
User | Count |
---|---|
90 | |
10 | |
10 | |
10 | |
7 | |
7 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.