function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Curtis ParisCurtis Paris 

Exception performing Query from Partner WSDL

While trying to Query against Contact, I am getting an exception from within the Axis API.  Below is the SOAP that I'm sending and receiving back. 

The response looks incorrect because it is defining Contact as an Enterprise object and not giving it back as an SObject.   The deserializer tries to deserialize it using the Enterprise namespace/object which breaks things. 


<?xml version="1.0" encoding="UTF-8"?>
<soapenv:Envelope xmlns:soapenv="" xmlns:xsd="" xmlns:xsi="">
  <ns1:SessionHeader soapenv:actor="" soapenv:mustUnderstand="0" xmlns:ns1="SforceService">
   <ns2:sessionId xmlns:ns2="">DON'T PEEK AT THIS</ns2:sessionId>
  <query xmlns="">
   <queryString>select Id from Contact</queryString>


ERROR [ Sync, SALESFORCE_FOLDER.ID=83109, rnd=-2001560631] ( - Exception:

org.xml.sax.SAXException: No deserializer for {}Contact

 at org.apache.axis.encoding.ser.BeanDeserializer.onStartChild(

 at org.apache.axis.encoding.DeserializationContextImpl.startElement(

 at org.apache.axis.message.SAX2EventRecorder.replay(

 at org.apache.axis.message.MessageElement.publishToHandler(

 at org.apache.axis.message.RPCElement.deserialize(

 at org.apache.axis.message.RPCElement.getParams(

 at org.apache.axis.client.Call.invoke(

 at org.apache.axis.client.Call.invoke(

 at org.apache.axis.client.Call.invoke(

 at com.sforce.soap.partner.SoapBindingStub.query(

 at com.metro1.metrodex.salesforce.SFCSynchronizer.sfcGetUpdated(


 at com.metro1.util.ThreadPool$


<soapenv:Envelope xmlns:soapenv="" xmlns:xsd="" xmlns:xsi="">
  <queryResponse xmlns="">
    <queryLocator xsi:nil="true"/>
    <records xsi:type="sf:Contact" xmlns:sf="">
    <records xsi:type="sf:Contact" xmlns:sf="">
    <records xsi:type="sf:Contact" xmlns:sf="">


Hi Curtis,

Check the endpoint that you are using.  If you generated stubs from the partner wsdl it should end in Soap/u/4.0, if you used the enterprise wsdl then it should end in Soap/c/4.0.