Table of Contents |
---|
"CRUD" Request Types
Read
Read object data from the database. This API will filter the objects based on the field names and values in the data portion of the request. There is no way to limit the fields returned by this API, so full object data will always be returned.
...
Note |
---|
Caveat Programmer!
|
Code Block |
---|
Info |
When Pulsar is in online mode, the |
Code Block |
---|
var request = {
"type" : "updateQuery",
"object" : "Account",
"data" : { "query" : "UPDATE Account SET ActiveCustomer__c = 'TRUE' WHERE OpportunityCount__c > 0;" }
};
bridge.sendRequest(request, function (responseData) {
alert('Javascript got its update query response: ' + responseData);
}); |
Sample Response (with a reported Salesforce error):
Code Block |
---|
Response: { "type": "updateQueryResponse", "object": "Account", "data": "datasuccess", : { "queryerrors" : "UPDATE[ Account SET ActiveCustomer__c = 'TRUE' WHERE OpportunityCount__c > 0;" } }; bridge.sendRequest(request, function (responseData) { alert('Javascript got its update query response: ' + responseData); }); { "errorCode": "ENTITY_IS_LOCKED", "message": "This record is locked. If you need to edit it, contact your admin." } ] } |