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
venkateshvenkatesh 

Exception in Webservice Call

Hi, I am making the webservice GET and POST to the database from Salesforce. Some of the time am getting "User Key Not specified." exception as a response for that POST call while posting XML data to the external database. Please inform me the details if any one facing the same issue.

 

Please tell me solution if any for this issue.

 

Thanks in advance.

aalbertaalbert

Are you making a callout from salesforce to an external database? Is that error coming from that web service? Assuming the callout is written in Apex, have you outputted the request and response to see the full message? 

venkateshvenkatesh

Hi aalbert, Yes, I am making the callout to an external database  from Salesforce (callout written in Apex) and getting the error coming from that web service. I have the log message to see the full message of request and response. Below I have pasted the XMLString whatever I am posting to external database and Response getting for the same:

 

XMLString :-<C_BPartner_Location><C_BPartner_ID><Value>1000015</Value></C_BPartner_ID><C_Location_ID><Address1><Value>#1223, BridgeMount</Value></Address1><City><Value>Sunnyvale</Value></City><Postal><Value>123456</Value></Postal><C_Country_ID><Info>United States</Info></C_Country_ID><C_Region_ID><Info>CO</Info></C_Region_ID></C_Location_ID><Phone><Value>123445</Value></Phone><Fax><Value>124256</Value></Fax></C_BPartner_Location>

 

Response :- <?xml version="1.0" encoding="UTF-8" standalone="yes"?><queryResponse><responseCode>401</responseCode><responseString>User Key Not specified.</responseString></queryResponse>

 

 

Please review the same. If you want any more explanation, please ask me. 

 

Please give me some kind of suggetion. Also I would like to know whether this might be the problem of external data base or problem with the Apex call out within the Salesforce.

 

Thanks a lot for your quick reply.

Message Edited by venkatesh on 06-28-2009 12:42 AM
Message Edited by venkatesh on 06-28-2009 04:18 AM
aalbertaalbert
Since the error is coming from the external web service, you will need to understand what that specific error message infers on that side. Can you debug the external web service?
ScorpionKingScorpionKing

Hi aalbert,

The thing is , what ever XML we are sending while updation with Webservice url are working perfectly when we are trying from eclispe (using our webservice java class).But the same sometimes gives user key not specified exception from time to time when we are making call from SFDC. This exception is mainly coming while posting XML data though web service. So wanted to know if there is something that causes our URL go wrong sometimes .

 

 

 

any help will be greatly appreciated.