JDBC Driver for Salesforce

Build 22.0.8462

CreateBatch

Creates a Salesforce batch.

Table-Specific Information

To create a batch, specify the Id of the Job you are adding it to and the XML aggregate of the batch itself. For example, the XML aggregate may resemble the following:

<?xml version="1.0" encoding="UTF-8"?>
<sObjects xmlns="http://www.force.com/2009/06/asyncapi/dataload" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <sObject>
    <FirstName>Bill</FirstName>
    <LastName>White</LastName>
  </sObject>
  <sObject>
    <FirstName>Bob</FirstName>
    <LastName>Black</LastName>
  </sObject>
</sObjects>

Note: The objects contained in the XML aggregate must all correspond to the object associated with the Job being used.

Input

Name Type Description
JobId String Id of the job the batch is being added to.
Aggregate String The aggregate of objects being added. Specifies the query to use if performing a batch query.
ContentType String The content type for the job. The valid values are: CSV, XML, ZIP_CSV, and ZIP_XML. Set the value to CSV if performing a batch query

The default value is XML.

Result Set Columns

Name Type Description
ID String The Id of the batch.
JobID String The Id of the job.
ApexProcessingTime String The number of milliseconds taken to process triggers and other processes related to the batch data. If there are no triggers, the value is 0. This does not include the time used for processing asynchronous and batch Apex operations. See also ApiActiveProcessingTime and TotalProcessingTime. This field is available in API version 19.0 and later.
ApiActiveProcessingTime String The number of milliseconds taken to actively process the batch. This value includes ApexProcessingTime, but not the time the batch waited in the queue to be processed or the time required for serialization and deserialization. See also TotalProcessingTime. This field is available in API version 19.0 and later.
CreatedDate String The date and time in the UTC time zone when the batch was created. This is not the time processing began, but the time the batch was added to the job.
NumberRecordsFailed String The unique, 18 character Id for the job associated with this batch.
NumberRecordsProcessed String The number of records processed in this batch at the time the request was sent. This number increases as more batches are processed.
State String The current state of processing for the batch. For instance, Queued, InProgress, Completed, Failed, or Not Processed.
StateMessage String Contains details about the state. For example, if the state value is Failed, this field contains the reasons for failure. If there are multiple failures, the message may be truncated. If so, fix the known errors and resubmit the batch: Even if the batch failed, some records could have been completed successfully.
SystemModstamp String The date and time in the UTC time zone that processing ended. This is only valid when the state is Completed.
TotalProcessingTime String The number of milliseconds taken to process the batch. This excludes the time the batch waited in the queue to be processed. See also ApexProcessingTime and ApiActiveProcessingTime. This field is available in API version 19.0 and later.

Copyright (c) 2023 CData Software, Inc. - All rights reserved.
Build 22.0.8462