Bulk Write Rows
Catalyst enables you to perform bulk write jobs on a specific table present in the Data Store. The bulk write operation can fetch thousands of records from a CSV file uploaded in Stratus and insert them in a specific table.
The table is referred to by its unique table ID that is generated by Catalyst during creation. The column in which the write operation must be performed is referred to by its unique column ID.
| Parameter Name | Data Type | Definition |
|---|---|---|
| tableID | String | A Mandatory parameter. Will hold the ID of the table to which data has to be written. |
| find_by | String | A Mandatory parameter. Will hold the name of the column to which data has to be written. |
| fk_mapping | Array | A Mandatory parameter. Will hold the local_column and reference_column details. |
| operation | String | A Mandatory parameter. The value of this parameter should be insert. |
| object_details | JSON Object |
|
Copy the SDK snippet below to perform a bulk write job on a particular table. To know more about the component instance datastore_service used below, please refer to this help section.
datastore_service = app.datastore()
bulk_write = datastore_service.table("Sample").bulk_write()
object_details = {
"bucket_name": "zcstratus12345",
"object_key": "sample.csv",
"version_id": "64832huidksnd83"
}
#create bulk write job
bulk_write_job = bulk_write.create_job(object_details, {
"find_by": "S1",
"fk_mapping": [
{"local_column": "EmployeeID", "reference_column": "EmpId"},
{"local_column": "DepartmentID", "reference_column": "DepId"}
],
"operation": "insert"
})
#get bulk write status
status = bulk_write.get_status('6759000000167103')
#get bulk write result
result = bulk_write.get_result('6759000000167103')
Last Updated 2025-11-11 12:11:26 +0530 IST
Yes
No
Send your feedback to us