new Bulk(conn)
Class for Bulk API
Parameters:
Name | Type | Description |
---|---|---|
conn |
Connection | Connection object |
Classes
Members
-
pollInterval :Number
-
Polling interval in milliseconds
Type:
- Number
-
pollTimeout :Number
-
Polling timeout in milliseconds
Type:
- Number
Methods
-
createJob(type, operation, options) → {Bulk~Job}
-
Create a new job instance
Parameters:
Name Type Argument Description type
String SObject type operation
String Bulk load operation ('insert', 'update', 'upsert', 'delete', or 'hardDelete') options
Object <optional>
Options for bulk loading operation Returns:
- Type
- Bulk~Job
-
job(jobId) → {Bulk~Job}
-
Get a job instance specified by given job ID
Parameters:
Name Type Description jobId
String Job ID Returns:
- Type
- Bulk~Job
-
load(type, operation, options, input, callback) → {Bulk~Batch}
-
Create and start bulkload job and batch
Parameters:
Name Type Argument Description type
String SObject type operation
String Bulk load operation ('insert', 'update', 'upsert', 'delete', or 'hardDelete') options
Object <optional>
Options for bulk loading operation Properties
Name Type Argument Description extIdField
String <optional>
External ID field name (used when upsert operation). input
Array.<Record> | stream.Stream | String <optional>
Input source for bulkload. Accepts array of records, CSv string, and CSV data input stream. callback
Callback.<Array.<RecordResult>> <optional>
Callback function Returns:
- Type
- Bulk~Batch