Initialising the Database
Before running a download you’ll need to initialise the target SQL Server database. This will setup all the necessary database objects, define the default settings and extract the initial state of the source Salesforce instance metadata to SQL Server. Run sf_download init with the following options.
Switch | Required | Notes |
---|---|---|
-S | Y | The SQL Server instance to download to |
-D | Y | The SQL Server instance to target |
-u | Y | The Salesforce user to connect with |
-p | Y | The Salesforce user password |
-t | Y | The Salesforce user token |
-n | N | If set the download will extract all existing objects and new objects whenever they are added in Salesforce. If you do to specify -n no objects will be downloaded until they are explicitly specified for download using the objects command |
-m | N | Specify the default download method. This will be used for all objects unless otherwise specified using the object command. The options are: SOAP | Bulk | Batched. If not set the default is SOAP. |
-i | N | Specify the default integration method. This will be used for all objects unless otherwise specified using the object command. The options are: Incremental | Delete. If not set the default is incremental. |
Examples
Initialise a database with default options. Objects to be downloaded need to be specified manually
sf_download init -S myInstance -D myDB -u myuser@shetland.com -p pass123 -t 2172LYjUfD9Ac0n9uA0dP1L3
Initialise a database specifying all objects to be downloaded with Bulk and Delete options
sf_download init -S myInstance -D myDB -u myuser@shetland.com -p pass123 -t 2172LYjUfD9Ac0n9uA0dP1L3 -n -m Bulk -i Delete