1-800-GOT-JUNK?
Splitting a Salesforce org with 16M records
Moving two brands out of a shared Salesforce org: about 16M records migrated, 99.97% loaded cleanly, no critical issues after go-live.
- records migrated
- ~16M
- loaded cleanly
- 99.97%
- of parent links traced to build clean load sets
- 9 levels
- lower cost of a schedule change
- ~70%
Several brands shared one Salesforce org. I led the program that moved two of them into dedicated orgs of their own, working with an implementation partner. About 16 million records were migrated, 99.97% loaded cleanly, and there were no critical issues after go-live. During the migration, loads stalled on broken record relationships. I designed a dependency analysis that traced parent links up to nine levels deep and produced clean load sets, and with the data migration lead and the team we fixed 90% of the integrity issues in two weeks.
The problem
The goal: give two brands Salesforce orgs of their own, with their own data and configuration, without disrupting the business while it ran.
Moving a brand out is not a copy. Salesforce records point to each other: a contact to an account, an activity to almost anything, custom objects to both. Each record must be loaded after everything it points to, with every reference translated to the new org’s IDs. Miss one link and the load fails, or worse, succeeds with a broken relationship.
Constraints
- A live business. The brands kept booking work every day, so launches were staggered.
- Years of history. Data created over many years carried every past process, and its orphans.
- Several parties. An implementation partner, internal teams and each brand’s leaders all had a stake in the scope and the schedule.
- Cost. Licenses and schedule changes both had a price.
What I built
The program. I led it end to end: scope, schedule, risks, and the coordination between the partner, internal teams and the brands.
Cost decisions. I chose a migration tool with no license cost, stood up the new brands’ data warehouses with Fivetran, and moved deployment work in-house, which cut the cost of a schedule change by about 70%.
The dependency analysis. When the loads stalled, I designed a metadata-driven analysis in KNIME and Redshift SQL. It used the org’s metadata to find the relationships between objects, followed each record’s parent links up to nine levels deep, and produced clean load sets: records that could load safely because everything they depended on was sound. Records with a broken chain went to cleansing instead of failing in a load.
How it works
- Read the metadata. The lookups and parent-child relationships between objects form a dependency graph.
- Walk the chains. For each record, follow its parents, and their parents, up to nine levels.
- Split. Records whose whole chain is sound form a clean load set; records with a missing or broken link go to cleansing.
- Load in order. Parents before children.
Because it was driven by metadata rather than written object by object, the same analysis could run again after each round of cleansing.
Results
- About 16 million records migrated, with 99.97% loaded cleanly.
- No critical issues after go-live.
- 90% of integrity issues fixed in two weeks once the dependency analysis was in place.
- ~70% lower cost for a schedule change, by bringing deployment work in-house.
This was a team result. The data migration lead, the internal teams and the partner did the heavy lifting on the loads; my contribution was leading the program and designing the analysis that got the loads moving again.
What I’d do differently
Run the dependency analysis before the first load. We built it to unblock stalled loads. Run at the start, it would have turned the integrity problems into a cleansing backlog weeks earlier.