• DevAngel2
  • NEWBIE
  • 0 Points
  • Member since 2003

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
    Questions
  • 17
    Replies

Hi there ,

I am  using Salesforce soap api to build the our application in asp/vb.net 2003. while debugging  I encounter logins and logout  enumurous time. but problem arises when i have to close application without logout. if i do it for several times (say more than 10 times) the soap api Starts giving error " object refrence not set to an instance"  in logon call.

the error continues  for for another 1-2 hours. till than i have to stop my work and sit back.

Please help!!

Thanx,
DotNetDevil.

 

Hey DevAngel!

I am having trouble with a batch update. Here is the soap request:

 

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:tns="salesforce" xmlns:types="salesforce/encodedTypes" soap:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
 <soap:Header>
  <headerStruct>
   <session_id xsi:type="xsd:string">g1IZodnymEdPbz.RjxCwsmH4wGeI6ygXsruXndS3cwNZZoI_J4af7jwNuh9x1rTi_ek7G0Mnsvzbe5lYbeG83vbtzKggVlhL</session_id>
   <version xsi:type="xsd:string">2</version>
  </headerStruct>
 </soap:Header>
 <soap:Body soap:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
  <qry1:batch xmlns:qry1="sfconnector:SalesforceConnector" type="methodCall">
   <type xsi:type="xsd:string">account</type>
   <operation xsi:type="xsd:string">update</operation>
   <arguments href="#id1"/>
   <soapenc:Array id="id1" soapenc:arrayType="xsd:anyType[1]">
    <Item href="#2"/>
   </soapenc:Array>
   <soapenc:Array id="2" soapenc:arrayType="tns:mapEntry[2]">
    <Item href="#2A"/>
    <Item href="#2B"/>
   </soapenc:Array>
   <tns:mapEntry id="2A" xsi:type="tns:mapEntry">
    <key xsi:type="xsd:string">cf_00N30000000c27H</key>
    <name xsi:type="xsd:double">0</name>
   </tns:mapEntry>
   <tns:mapEntry id="2B" xsi:type="tns:mapEntry">
    <key xsi:type="xsd:string">id</key>
    <name xsi:type="xsd:string">000000000000000</name>
   </tns:mapEntry>
  </qry1:batch>
 </soap:Body>
</soap:Envelope>

 

Also, I am trying to generate an error response from the server in the above xml.

Thanx!

  • September 26, 2003
  • Like
  • 0

Dev,

Thanx for your reply on the sorting.

I have another Query. Its regarding the allDay event.

I am retrieving today's event based on the date-time of today (such as 09/25/03 00:00 AM to 09/26/03 00:00 AM). I am able to view all the event details properly but for the allDay event. How to get an allDay event along with other events?

Thanx

mPortalwiz

 

Hi all,

I have a web integration link that passes the session id to my script, so i can make updates into my currently running salesforce instance (lets call my developer account A)

 

However, with this same integration link and script, on a DIFFERENT account (lets call it account B)... i get a

session id invalid or missing error.. (it's definitely not missing)

are there certain options enabled in my A account that is turned off in B's account (regular customer account)

thank you for your time

Is it possible to associate a note or attachment with a lead?

The SForce ERD shows the "parentId" field relates notes & attachments to opportunities, cases, solutions, campaigns, contacts & accounts but leads do not appear on the diagram.

 

 

D.

 

API code that has been running unchanged and without incident suddently started producing errors today.  Can I assume that the problem is not on my end, and any ideas how long a resolution might take?

Thanks.

  • August 06, 2003
  • Like
  • 0

I'm trying to retrieve an opportunity using a modified version of the sample from the API document.  This used to work for me, but it stopped working for me this evening.  I receive an error saying that the select list is not specified.

The SOAP request is as follows:

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:tns="salesforce" xmlns:types="salesforce/encodedTypes" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">

<soap:Header>

<tns:headerStruct id="id1">

<session_id xsi:type="xsd:string">{SessionID}</session_id>

<version xsi:type="xsd:string">2.0</version>

</tns:headerStruct>

</soap:Header>

<soap:Body soap:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">

<q1:query xmlns:q1="sfconnector:SalesforceConnector">

<type xsi:type="xsd:string">opportunity</type>

<maxRows xsi:type="xsd:int">200</maxRows>

<scope xsi:type="xsd:string">filter</scope>

<select href="#id1"/>

<filter href="#id2"/>

</q1:query>

<soapenc:Array id="id1" soapenc:arrayType="xsd:string[4]">

<Item>id</Item>

<Item>ownerID</Item>

<Item>name</Item>

<Item>accountID</Item>

<Item>type</Item>

<Item>leadSource</Item>

<Item>amount</Item>

<Item>expectedAmount</Item>

<Item>closeDate</Item>

<Item>nextStep</Item>

<Item>stage</Item>

<Item>probability</Item>

<Item>campaignID</Item>

<Item>description</Item>

<Item>closed</Item>

<Item>won</Item>

<Item>forecastCategory</Item>

<Item>createdDate</Item>

<Item>lastModifiedDate</Item>

</soapenc:Array>

<soapenc:Array id="id2" soapenc:arrayType="xsd:anyType[1]">

<Item href="#id3"/>

</soapenc:Array>

<soapenc:Array id="id3" soapenc:arrayType="tns:mapEntry[3]">

<Item href="#id4"/>

<Item href="#id5"/>

<Item href="#id6"/>

</soapenc:Array>

<tns:mapEntry id="id4" xsi:type="tns:mapEntry">

<key xsi:type="xsd:string">field</key>

<value xsi:type="xsd:string">{Field}</value>

</tns:mapEntry>

<tns:mapEntry id="id5" xsi:type="tns:mapEntry">

<key xsi:type="xsd:string">value</key>

<value xsi:type="xsd:{ValueType}">{Value}</value>

</tns:mapEntry>

<tns:mapEntry id="id6" xsi:type="tns:mapEntry">

<key xsi:type="xsd:string">operator</key>

<value xsi:type="xsd:string">{Operator}</value>

</tns:mapEntry>

</soap:Body>

</soap:Envelope>

  • August 06, 2003
  • Like
  • 0

Hi,

 I wrote one java program to fetch an opportunity details using query method.(scope is idList).

It was worked well upto yesterday.  When I run the same program Today I am getting SOAP fault with

fault string  select list not specified in query.

Please let me know whether there  is  any change in the  API?  .

I am including my soap request at the end. Please look at the message and advise me if there is any change.

any help would be much appreciated.

Thanks and regards,

Prudhvi

 

 

I am using following soap request to fetch the opp details.

Request:

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:tns="salesforce" xmlns:types="salesforce/encodedTypes" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
  <soap:Header>
    <tns:headerStruct id="id1">
      <session_id xsi:type="xsd:string">A88zC97HIqHnZIlRhIemUk5cNamuFFrgC8.mkYiGGVDEesUfciyliy._DWGd4UrmD1qjRrjmKArOo.rZcbQUIvbtzKggVlhL</session_id>
      <version xsi:type="xsd:string">2.0</version>
    </tns:headerStruct>
  </soap:Header>
  <soap:Body soap:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
    <q1:query xmlns:q1="sfconnector:SalesforceConnector">
      <version xsi:type="xsd:string">2.0</version>
      <session_id xsi:type="xsd:string">A88zC97HIqHnZIlRhIemUk5cNamuFFrgC8.mkYiGGVDEesUfciyliy._DWGd4UrmD1qjRrjmKArOo.rZcbQUIvbtzKggVlhL</session_id>
      <scope xsi:type="xsd:string">idList</scope>
      <type xsi:type="xsd:string">opportunity</type>
      <maxRows xsi:type="xsd:int">1</maxRows>
      <select href="#id1"/>
      <idList href="#id2"/>
    </q1:query>
    <soapenc:Array id="id1" soapenc:arrayType="xsd:string[9]">
      <Item>id</Item>
      <Item>name</Item>
      <Item>accountID</Item>
      <Item>type</Item>
      <Item>leadSource</Item>
      <Item>amount</Item>
      <Item>closeDate</Item>
      <Item>stage</Item>
      <Item>probability</Item>
      <Item>description</Item>
      <Item>closed</Item>
      <Item>won</Item>
      <Item>createdDate</Item>
      <Item>createdByID</Item>
      <Item>lastModifiedDate</Item>
      <Item>lastModifiedByID</Item>
    </soapenc:Array>
    <soapenc:Array id="id2" soapenc:arrayType="xsd:string[1]">
      <Item>00600000006qJqB</Item>
    </soapenc:Array>
  </soap:Body>
</soap:Envelope>

 

Response

 

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:tns="salesforce" xmlns:types="salesforce/encodedTypes" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema ">

<soap:Header/><soap:Body><soap:Fault><faultcode>ÑR</faultcode><faultstring>select list not specified in query</faultstring></soap:Fault></soap:Body></soap:Envelope>

Hi,

Our product use soap 2.2 and no intention to upgrade to Axis. Could I use soap 2.2 to use APIs 2.0. and How ?

 

Thanks

peilei

  • July 28, 2003
  • Like
  • 0

Hello,

I am a new user with a developer account. I can make most of the calls I needed using my developer account login to the URL http://na1.salesforce.com/servlet/servlet.SoapApi .When I need to login with a real account, I can't get it to work.  I then changed the URL to https://www.salesforce.com/servlet/servlet.SoapApi and I can login with a real account, but none of my calls work (ie query, describe).  What do I need to do?

Any help is appreciated.

John

I'm a newbie and using the vb.net (Soap calls) samples to get data in salesforce.

I can login and do searches on accounts, contacts, and opportunities.  Now I need to get fields data.

Do I start with a describe function? I do a  call below, but need to know how to parse the response.

sForce.describe("account")

Then I need to query for fields data. 

Any help is appreciated.

Have played with this for a number of days now.

We are using XML-RPC with salesforce API 2.0.

We have tried Java and VisualBasic with the same results.

Note that we can perform the login and describe calls without problem.

When we try to query anything (not search), we get this error:

<?xml version="1.0" encoding="UTF-8" ?><methodResponse><fault><value><struct><member><name>faultString</name><value>missing scope in query call</value></member><member><name>faultCode</name><value><int>1100</int></value></member></struct></value></fault></methodResponse>

Here is one of our queries:

----------------------------------------------------------------

<?xml version="1.0" encoding="UTF-8" ?>
<methodCall>
  <methodName>sfdc.query</methodName>
  <params><param><value><struct>
    <member>
      <name>version</name>
      <value><string>2.0</string></value>
    </member>
    <member>
      <name>type</name>
      <value><string>contact</string></value>
    </member>
    <member><name>filter</name>

    <value><array><value><struct>
    <member><name>operator</name><value>or</value></member>

 <member><name>value</name>
 <value><struct><member><name>operator</name>
 <value>starts with</value></member>
 <member><name>field</name><value>00N30000000bpgc</value></member>
 <member><name>value</name><value>TR</value></member></struct></value></member>

 <member><name>value</name>
 <value><struct><member><name>operator</name>
 <value>starts with</value></member>
 <member><name>field</name><value>00N30000000bpgc</value></member>
 <member><name>value</name><value>ET</value></member></struct></value></member>

 <member><name>value</name>
 <value><struct><member><name>operator</name>
 <value>starts with</value></member>
 <member><name>field</name><value>00N30000000bpgc</value></member>
 <member><name>value</name><value>EN</value></member></struct></value></member>

  </struct></value></array></value></member>

    <member>
      <name>select</name>
      <value><array>
        <value>accountID</value>
        <value>lastName</value>
        <value>firstName</value>
        <value>email</value>
      </array></value>
    </member>
  </struct></value></param></params></methodCall>

---------------------------------------------------

 

The fieldnames came from the describe call on the contacts.

There is no mention of 'scope' in the API manual, other than a reference to the type of data

we are querying (contact in this case).

We are sort of stuck.  Anyone have an idea? Anyone have a XML-RPC query that works?

 

Thanks for any assistance,

Al G

AlterPoint

  • July 03, 2003
  • Like
  • 0

I've been trying to insert properly encoded (base-64) data for attachments in C# but it's notworking.  In fact it is the same data that salesforce is passing me.  I am passing it as a string but I get "Value ... not of required type base64 on field body", so does that mean I have to pass it as a type other than a string? 

  • June 26, 2003
  • Like
  • 0