Skip to main content

Whenever I try to use the bulkapi, or pkchunk, or even just use SF_Mirror on a large table, it says that SF_Mirror fails. The message output looks like this:

--- Starting SF_Mirror for Account V8304
10:53:19: Parameters: salesforce2022 Account bulkapi Version: V8304
10:53:19: DBAmpAZ 22.0.8304.0 Copyright c 2021 CData Software, Inc.
10:53:19: Using options specified in Options parameter: bulkapi
10:53:19: Obtaining Connection Props
10:53:28: Obtaining User Information
10:53:31: Using settings from Registry.
10:53:33: Error: DBAmpWork directory does not exist.
10:53:33: DBAmpAZ Operation FAILED.
10:53:33: Error: MirrorCopy program was unsuccessful.
10:53:33: Error: Command string is C:\"Program Files"\CData\"CData DBAmp"\bin\DBAmpAZ.exe MirrorCopy "Account"  "DL-7KVJRL3"  "salesforce_backups2022"  "salesforce2022"  "bulkapi"
--- Ending SF_Mirror. Operation FAILED.
Msg 50000, Level 16, State 1, Procedure sf_mirror, Line 173 1Batch Start Line 1]
--- Ending SF_Mirror. Operation FAILED.

To use the bulkapi (even the pkchunk variant) you will need to have a Work Directory set up for DBAmp - that’s what that error means ( Error: DBAmpWork directory does not exist. ).

How to do that depends on your version. That output says you have version 22.0.8304.0 - any version that starts with 22 works the same, and you can set up the Work Directory in the DBAmp Configuration Program, in the Settings dialog under the Configuration menu. The Work Directory is in the Properties section there.

If you have an older version (that would look like v5.1.9, for example), you also need to go to the the DBAmp Configuration Program, and there you can find it in the Options dialog under the Configuration menu.

In both cases, make sure to choose a folder on your local drive that your SQL Server instance has read/write access to!


Hi Dani-

What are the best practices for cleaning up all the CSV files created in the DBamp Work Directory since overtime they accumulate and grow?  Are users supposed to monitor and remove the old ones or is there a dbamp configuration/service/stored procedure that can help with this?  Can the older ones be removed? and if so what’s a safe timeframe for their removal?

Currently using version 5.1.3.0 but will be upgrading soon.

Thanks for your help, Brad.


There is not a stored procedure/configuration for it, but any of them can be removed, as long as they are not ones *just* created, ie still in use by a running procedure.


Reply