Page tree
Skip to end of metadata
Go to start of metadata

Issue Description:

Row size limit for mysql table is 64kb. While replicating Salesforce into mysql table, if the row size is more than 64 kb, replication process is impacted. In such cases, it is required to replicate those objects into multiple tables by splitting the object fields into different tables. This section describes the process of replicating such objects into multiple tables with an example.

Solution:

  • While replicating Salesforce into mysql database using DBSync Replication, if the row size exceeds 64 kb, replication process stops and the logs will display an error as shown below.

Row size too large. The maximum row size for the used table type, not counting BLOBs, is 65535. You have to change some columns to TEXT or BLOBs.

  • Identify the Salesforce object which has row size greater than 64kb. These objects wouldn't have replicated into database when the row of size is greater than 64kb.
  • If accounts object has row size greater than 64kb, we need to replicate this accounts object into two different tables for example sf1_accounts & sf2_accounts. This can be done by creating a new profile in DBSync replication and running replication on both the profiles.
  • In this example, mysql is the primary profile in DBSync Cloud Replication to replicate Salesforce into mysql database. Salesforce and database details are already saved in the respective tabs in DBSync Cloud Replication console. New profile mysql_new should be created in DBSync Replication. Details of profile creation is available in the below wiki link.
  • table sf1_accounts will have only the standard fields & table sf2_accounts will have only custom fields. Go to installation folder of DBSync Cloud replication to add the prefix for mysql tables. Follow the below path in DBSync Cloud Replication installation folder to find the profile folders.
    • DBSync Cloud Replication Installation Folder (DBSyncCReplSF3) > dbsync-repl > WEB-INF > db > mysql
  • Go to config properties file in the profile folder for mysql and include the following codes in the file.

table.prefix=sf1
column.prefix=sf1

  • Follow the below path in DBSync Cloud Replication installation folder to find profile folder mysql_new.
    • DBSync Cloud Replication Installation Folder (DBSyncCReplSF3) > dbsync-repl > WEB-INF > db > mysql_new
  • Go to config properties file in the profile folder for mysql and include the following codes in the file.

table.prefix=sf2
column.prefix=sf2

  • Go to profile mysql_new of DBSync Cloud Replication Console and go to tab Salesforce Sync Object Details. Ensure that Salesforce and Database details are saved in the respective tabs. Click on Account, retain the custom field in Available Fields section and push all the standard fields in Exclude Fields and save the changes.
  • When you run replication for the profile mysql it replicates Salesforce Accounts into sf1_accounts which will have only Salesforce standard fields of Accounts object.
  • When you run replication for the profile mysql it replicates Salesforce Accounts into sf2_accounts which will have only Salesforce custom fields of Accounts object.
  • To get this Salesforce Accounts replicated completely, replication of profiles mysql and mysql_new is mandatory. Salesforce Accounts data will be saved in sf1_accounts and sf2_accounts. In case, scheduler is used to run the replication. Replication should be scheduled in both the profiles mysql & mysql_new.
  • No labels