The problem of Salesforce record IDs for deploying CPQ configuration
When a new record is created in a Salesforce org, a globally unique identification value is automatically generated in its ID field at the time of record creation.
Taking a scenario where you create a new product record entry (e.g. new
15” Laptop product) in a developer sandbox, you'll encounter the "changing record ID problem" as that record gets deployed along your pipeline until it reaches production.
This is because Salesforce automatically generates and assigns a completely different record ID for the same current
15” Laptop product record as it's deployed between each of your Salesforce orgs.
It leaves you in the unenviable situation where you now have exactly the same duplicated 15” Laptop product record in each of our Salesforce orgs. Worse still - there’s absolutely nothing to link the records together to tell you they’re the same because the IDs don’t match!
The solution: The New Gearset External ID Wizard!
So, how does Gearset solve the problem?
Gearset has developed a new external ID setup feature to create its own
Gearset external ID field, and populates it with its very own ID record value. The outcome being, as you deploy the record though the pipeline, it carries the same ID across all environments (essentially ignoring the Salesforce record ID after initially generating our own ID based on the existing Salesforce record ID).
The new external ID setup process provides a simple UI requiring only for you to select the Salesforce org that you wish to start the Gearset external ID process for and click
Create Gearset external IDs. It's as simple as that!
A 1-click process that can be applied to any of your Salesforce org connections.
How does the Gearset external ID setup wizard work?
Once you've chosen the Salesforce org connection and start the setup process, Gearset will automatically perform three simple steps behind the scenes:
Step 1: Gearset retrieves and performs a metadata check
Gearset looks at all the CPQ and related objects in your Salesforce org and checks for the existence of its
Gearset External ID, to understand which objects it needs to be added to.
Step 2: Gearset performs a metadata deployment
Gearset then performs a metadata deployment to add its external field (
GearsetExternalId__c) to the CPQ and related objects.
Note that, at this stage, only the field name exists, but no record ID values.
Step 3: Gearset performs a data deployment
Only once the metadata deployment is successful, Gearset performs a data deployment to populate the records with their own unique identifier that will consistently remain the same across all your environments.
The Gearset record ID is based upon the existing Salesforce record ID, reversed.
In the example above, Gearset initially generated and populated its own record ID value by simply looking at the existing Salesforce record ID value in the developer sandbox and reversing it. It then uses that same value as the record is deployed between environments maintaining a consistent ID to enable the comparison and deployment of records, and preventing duplicate records from being deployed.
For a walkthrough of the steps required to compare and deploy your CPQ configuration data, continue reading the next article.