SLAM_load
This generalized load method provides access to all three APIs and file loading through a single procedure. It delegates to the appropriate specific load procedure based on the @api parameter, making it a convenient choice when the API choice needs to be dynamic.
Parameters:
| Name | Type | Default | Description |
|---|---|---|---|
@sObject | NVARCHAR | Required | Salesforce object name to load data into |
@table | NVARCHAR | Required | Source SQL table containing data to load |
@api | NVARCHAR | Required | API to use ('bulk', 'bulkv2', 'soap' or 'blob') |
@operation | NVARCHAR | Required | Operation type ('insert', 'update', 'upsert', 'delete', 'hardDelete', 'undelete') |
@bulk_parallel | BIT | 1 | Bulk v1 API only. Enable parallel batch processing when set to 1. Serial mode when 0 |
@batch_size | INT | NULL | Records per batch for SOAP/Bulk v1 API. Uses API defaults if NULL |
@externalId | NVARCHAR | NULL | External ID field name (required for upsert operations, required for bulkv2) |
@ignore_nulls | BIT | 0 | SOAP API only. Whether to ignore NULL values when sending data. When set to its default value of 0, Speediful will send NULL and empty string data to Salesforce with the instruction to blank out the field. When set to 1, NULL values will be ignored (existing data will be preserved), but empty strings will continue to blank out the field. See NULL and Blank Handling for detailed behavior across all APIs |
@dwell_time | FLOAT | 0 | SOAP API only. Wait time between batches in seconds |
@soap_options | NVARCHAR | NULL | SOAP API only. Additional SOAP headers and options. See SOAP Headers |
Usage Examples:
Load using Bulk API with minimal parameters:
EXEC dbo.SLAM_load
@sObject = 'Account',
@table = 'Account_insert',
@api = 'bulk',
@operation = 'insert'
Load using Bulk v2 API with required external ID:
EXEC dbo.SLAM_load
@sObject = 'Contact',
@table = 'Contact_upsert',
@api = 'bulkv2',
@operation = 'upsert',
@externalId = 'External_Contact_Id__c'
Load using SOAP API with full control options:
EXEC dbo.SLAM_load
@sObject = 'Case',
@table = 'Case_load',
@api = 'soap',
@operation = 'insert',
@batch_size = 150,
@dwell_time = 2.0,
@soap_options = 'AllOrNoneHeader,allOrNone,true;EmailHeader,triggerUserEmail,false'