You need to sign in to do that
Don't have an account?
SFDC coder
Enterprise wsdl SOAP request for upsert.Am i on right track?
hi all,
i am trying to execute upsert call from enterprise wsdl via SOAP UI tool
below is my soap request.
Problem: i am unable to specify the object type.
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
and the upsert was successfull.Is this a correct way to add the namespace explicitly?
If i send such a wsdl to third party it would eventually fail
i am trying to execute upsert call from enterprise wsdl via SOAP UI tool
below is my soap request.
Problem: i am unable to specify the object type.
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:urn="urn:enterprise.soap.sforce.com" xmlns:urn1="urn:sobject.enterprise.soap.sforce.com"> <soapenv:Header> <urn:SessionHeader> <urn:sessionId>XXXXXXXXXXXXXXX</urn:sessionId> </urn:SessionHeader> </soapenv:Header> <soapenv:Body> <urn:upsert> <urn:externalIDFieldName>Product_Id__c</urn:externalIDFieldName> <!--Zero or more repetitions:--> <urn:sObjects urn:type="Product__c"> <!--Zero or more repetitions:--> <Product_Id__c>456721</Product_Id__c> <Name>My test</Name> <Product_Brand__c>HIGHLAND PARK</Product_Brand__c> </urn:sObjects> </urn:upsert> </soapenv:Body> </soapenv:Envelope>When i run this request i get the below response
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:sf="urn:fault.enterprise.soap.sforce.com" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <soapenv:Body> <soapenv:Fault> <faultcode>sf:INVALID_TYPE</faultcode> <faultstring>INVALID_TYPE: Must send a concrete entity type.</faultstring> <detail> <sf:InvalidSObjectFault xsi:type="sf:InvalidSObjectFault"> <sf:exceptionCode>INVALID_TYPE</sf:exceptionCode> <sf:exceptionMessage>Must send a concrete entity type.</sf:exceptionMessage> <sf:row>-1</sf:row> <sf:column>-1</sf:column> </sf:InvalidSObjectFault> </detail> </soapenv:Fault> </soapenv:Body> </soapenv:Envelope>i then added the namespace to my request
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
and the upsert was successfull.Is this a correct way to add the namespace explicitly?
If i send such a wsdl to third party it would eventually fail
To get session id; you can do below in debug log Then pickup this Session Id value and put it in your request and you should see Success!
PS: if this answers your question then hit Like and mark it as solution!
All Answers
To get session id; you can do below in debug log Then pickup this Session Id value and put it in your request and you should see Success!
PS: if this answers your question then hit Like and mark it as solution!
However i see that we need to pass record id for deletion.Can we pass external id instead of record id?Is that possible?
if yes then what do i modify in the below delete soap request?
Can you try below as body? So your SOAP body will look like below: It would be great to start a new thread for any new discussions rather than mixing all stuff at one place so that other people get advantage out of it. Hence, it will be great if you mark my previous response as answer and start new discussion for new question. I will definately help you wherever you need me.
PS: if this answers your question then hit Like and mark it as solution!
https://developer.salesforce.com/forums/ForumsMain?id=906F0000000AnpsIAC
thanks
Error :
INVALID_TYPE Must send a concrete entity type. -1 -1