MySQL to Salesforce, syncing connections between tables

  • 162Views
  • Last Post 11 July 2017
  • Topic Is Solved
0
votes
Adam Deyes posted this 10 July 2017

Hi, I'd like to know if this software can sync, not only data between 2 tables, (explain Mysql table to salesforce object) but also if it can sync data between connections. Maybe my example might help better:

 

I have a Table called User, and another called 'Application Form', in MySQL database.

Application has a FK to User.

User is synced to salesforce contacts.

Salesforce also has 'Application Form'.

 

How do I sycn data between MySQL and Salesforce for 'Application Form' While also connection the contact to that 'Application Form' in salesforce?

All data will be coming from MySQL database.

0
votes
Simon Bubnov posted this 11 July 2017

Skyvia allows you to import related objects with saving relation in a target source.

 

Skyvia Synchronization package synchronizes data between a source and a target in both directions. When synchronization is performed for the first time, it does not check whether the records in sources are identical and simply copies data from one side to another and vice versa, and "maps" the original records to their copies in another source. During subsequent synchronizations, if a record is modified or deleted in one source, Skyvia modifies or deletes the data, mapped to this record in another source, and vice versa.

 

> All data will be coming from MySQL database.

 

If all the data should be loaded in one direction, from MySQL, you can use an import package.

 

If you mean to import related data to Salesforce while preserving relations between the imported source objects in target, you can do it in two ways.

1) Use a relation mapping. When using the Relation mapping, Skyvia imports the data to the parent entity first and remembers the corresponding target Ids of the inserted records. When child records are imported, Skyvia will assign the corresponding new Ids to the corresponding foreign key field, thus preserving the source relation in target. For more information, please refer to https://skyvia.com/resources/docs/index.html?relation_mapping.htm

 

2) Use a lookup mapping to find the corresponding parent id value in the target by comparing some unique field of the parent object in target with the corresponding unique field in source. For more information, please refer to https://skyvia.com/resources/docs/index.html?lookup_mapping.htm

 

Here is how to create a package that imports data from MySQL tables to Salesforce with preserving relations:

1. Create an import package with MySQL as the source, and Salesforce as the target;

2. Select or create the connections to the data sources. For more information, please refer to:

https://skyvia.com/resources/docs/index.html?mysql_connections.htm

https://skyvia.com/resources/docs/index.html?salesforce_connections.htm

3. Add a new task;

4. Select the User table in MySQL and click Next;

5. Select User in Salesforce and click Next;

6. After this you need to configure mapping. For more information, please refer to https://skyvia.com/resources/docs/index.html?mapping.htm

7. When mapping is configured, click Finish;

8. Add a new task;

9. Select the Application Form table in MySQL and click Next;

10. Select Application Form in Salesforce and click Next;

11. After this you need to configure mapping. For the foreign key field, referencing to the User object, in Salesforce Application Form select relation mapping. And select relation corresponding to the User object.

12. When mapping is configured, click Finish;

13. Click Save.

 

This package will import data to the User entity first. Then it will import data to the Application Form and will insert the corresponding IDs to the foreign key field.

 

You can also use the upsert operation to avoid creating duplicates. Salesforce target supports 2 way of using the upsert operation: via External Id and via Lookup mapping for the Id by any unique field. For more information, please refer to https://skyvia.com/resources/docs/index.html?performing_upsert_operation.htm . You need to select the upsert operation instead of insert on the steps 5 and 10.

Close