How to use Bulk Query with PK chunking in Salesforce Plugin 6.x
book
Article ID: KB0083334
calendar_today
Updated On:
Products
Versions
TIBCO ActiveMatrix BusinessWorks Plug-in for Salesforce.com
6.2
Description
What is PK chunking? A- PK Chunking request header enables automatic primary key (PK) chunking for a bulk query job. PK chunking splits bulk queries on very large tables into chunks based on the record IDs, or primary keys, of the queried records. Each chunk is processed as a separate batch that counts toward your daily batch limit, and you must download each batch’s results separately. PK chunking is supported for the following objects: Account, Campaign, CampaignMember, Case, Contact, Lead, LoginHistory, Opportunity, Task, User, and custom objects. PK chunking works only with queries that don’t include SELECT clauses or conditions other than WHERE.
How to use Bulk Query with PK chunking by using Salesforce.com plugin:
Issue/Introduction
How to use Bulk Query with PK chunking in Salesforce Plugin 6.x
Environment
All OS
TIBCO BusinessWorks 6.x
TIBCO ActiveMatrix BusinessWorks Plugin for Salesforce.com
Resolution
If you want to use PK chunk functionality, please find below how to popoulate the sforce-Enable-PK-Chunking field:
where 1. chunksize specifies the number of records within the ID boundaries for each chunk 2. startRow specifies the 15-character or 18-character record ID to be used as the lower boundary for the first chunk.
Currently only csv data type is supported by PK chunking on Salesforce.com plugin. XML and JSON are not supported.
TIBCO Salesforce.com has a provision for PK chunking but currently salesforce is not allowing to use PK chunking with XML data type. We will run into below error.
InternalServerError : PKChunking failed. InvalidBatch : Wrong content-type for batch (text/csv), job is of type: application/xml
This is a known issue from salesforce.com. Currently, BULK API -PK Chunking Header Query does not support application/xml as a content type and only supports text/csv as a data type.
Please refer to link:https://success.salesforce.com/issues_view?id=a1p300000008ZL6AAM
Attachments
How to use Bulk Query with PK chunking in Salesforce Plugin 6.x
get_app