Syncing Accounts & Organizations

Configuring which data to import from your warehouse

Note: The below instructions cover how to sync Accounts from your warehouse into Vitally. If you're using our Account hierarchy feature and have Organizations enabled, the same steps can be followed to sync Organizations from your warehouse into Vitally.

Step 1 - Query

After connecting to your warehouse, you can start syncing Accounts by configuring the query that Vitally will run against your warehouse on each incremental sync.

Once you've entered your query, be sure to click the Preview Query button, which will execute your query against your warehouse and return the first row fetched from your targeted table.

Each column of the result will be presented as an available trait that you can pull into Vitally as an account trait.

You'll use the previewed query and returned row further along in the configuration below.

Incremental Sync

Incremental sync is a process of syncing warehouse data that has only been added or modified since the last sync cycle, instead of processing the entire dataset each time. This approach is more efficient as it minimizes the amount of data queried and processed during each sync, making the update process quicker and resource-efficient.

Incremental syncs are highly recommended for syncing Accounts

If you'd like Vitally to incrementally query your data each time, you'll need to add a clause to your query with the variable $LAST_SYNC_TIMESTAMP. We'll fill in that variable with the timestamp of the last sync each time we query the warehouse.

Incremental syncs should compare the $LAST_SYNC_TIMESTAMP with a timestamp that reflects when the data was synced to the data warehouse. This is particularly important when data is synced to the data warehouse in batches.

FROM "Customer"

Step 2 - Configure

Once you input and preview your query, you'll be presented with a few additional configuration options:

External ID

Vitally will create or update accounts from each row based on the External ID of the account. This ID should be shared across your other integrations - its significance is described in The Significance of External ID. This is likely the primary key of the account in your warehouse, or the primary key of the account in your main data store.

Create vs Update only

Once you select an external ID, you have the option of determining whether your warehouse can create new accounts in Vitally or only update existing ones (created from another source).

(Optional) Specifying a fallback ID

If you choose to sync Accounts/Organizations by their "External ID", you'll see another question asking about a 'fallback ID':

This is optional but useful if there is a delay in the "External ID" being set on your Accounts/Organizations. For example, say you sign a new contract with a customer but don't provision their product instance for a few weeks. If your "External ID" is the primary ID of the Account in your database, you won't have that ID until their instance is provisioned, meaning they won't show in Vitally until that occurs. To resolve this, you can specify a 'fallback ID' here. The Vitally platform will then create Accounts using this fallback ID if the primary external ID is not set. Once the primary external ID is set on the Account, Vitally will automatically switch the ID over to the primary and merge any duplicate Accounts created from other systems.


Lastly, you'll be asked to specify which column in your select should be used as the account's name in Vitally.

Step 3 - Continue Configuration

If you have other features to sync continue configuring those.

pageConfiguring Sync

OR Step 3 - Enable Sync

pageEnabling Sync

Last updated