SalesforceCommerceCloud / b2c-crm-sync

... a contemporary perspective on how to integrate B2C Commerce and the Salesforce Customer 360 Platform to power frictionless customer experiences in the B2C domain.
https://salesforcecommercecloud.github.io/b2c-crm-sync/
BSD 3-Clause "New" or "Revised" License
64 stars 47 forks source link

Create and Deploy Your Duplicate Rules Fails. when force deployed results in error : SortOrder must be in sequential order from 1. #120

Open neeraj-jain01 opened 2 years ago

neeraj-jain01 commented 2 years ago

-- Deploying the configured duplicate rules to the Salesforce Org -- Unable to deploy the duplicateRules to your Salesforce Org -- Please deploy the rules manually via the following SFDX command:

sfdx force:source:deploy -p "./src/sfdc/base/main/default/duplicateRules/"

npm run crm-sync:sf:duplicaterules ... -- Review the CLI output for details regarding possible errors -- If issues remain unresolved, consider creating the duplicateRules -- manually (see "src/sfdc/_templates/duplicateRules" for details)

CRM-SYNC | v0.9.0 | crm-sync:sf:duplicaterules: END

neeraj.jain@neerajjain-ltm b2c-crm-sync-master % sfdx force:source:deploy -p "./src/sfdc/base/main/default/duplicateRules/" Deploying v52.0 metadata with SOAP API v53.0 connection Deploy ID: 0Af5j00000BhOSACA3 SOURCE PROGRESS | ████████████████████████████████████████ | 2/2 Components

=== Component Failures [1] Type Name Problem ───── ──────────────────── ───────────────────────────────────────────── Error Contact.B2C_Commerce SortOrder must be in sequential order from 1.

ERROR running force:source:deploy: Deploy failed. neeraj.jain@neerajjain-ltm b2c-crm-sync-master %

olegforce commented 2 years ago
 -- Unable to deploy the duplicateRules to your Salesforce Org
 -- Please deploy the rules manually via the following SFDX command:

    sfdx force:source:deploy -p "./src/sfdc/personaccounts/main/default/duplicateRules/"

 -- Review the CLI output for details regarding possible errors
 -- If issues remain unresolved, consider creating the duplicateRules
 -- manually (see "src/sfdc/_templates/duplicateRules" for details)
----------------------------------------------------------------------------
 CRM-SYNC | v0.9.0 | crm-sync:sf:duplicaterules: END
----------------------------------------------------------------------------
osapishchuk@osapish-ltmsol0 b2c-crm-sync % sfdx force:source:deploy -p "./src/sfdc/personaccounts/main/default/duplicateRules/"
*** Deploying v52.0 metadata with SOAP API v53.0 connection ***
Deploy ID: 0Af5j00000EwmJHCAZ
DEPLOY PROGRESS | ████████████████████████████████████████ | 1/1 Components

=== Component Failures [2]
Type   Name                                           Problem
─────  ─────────────────────────────────────────────  ─────────────────────────────────────────────────────────────────────
Error  Contact.B2C_Commerce_Standard_Person_Accounts  SortOrder must be in sequential order from 1.
Error  Contact.Standard_Contact_Duplicate_Rule        Contact.00N5j000000nLjG is not a valid condition field for : Contact.

ERROR running force:source:deploy:  Deploy failed.

Got the same issue when first run npm run crm-sync:sf:duplicaterules and after was asked to run sfdx force:source:deploy -p "./src/sfdc/personaccounts/main/default/duplicateRules/"

ast-ccorciega commented 2 years ago

@neeraj-jain01 getting the same issue, were you able to resolve?

olegforce commented 1 year ago

Doing an installation on another org, and got the same issue once again, but now the command that is recommended to fix it, is not working:

👾 >   sfdx force:source:deploy -p "./src/sfdc/base/main/default/duplicateRules/"
 ›   Warning: sfdx-cli update available from 7.142.1 to 7.182.1.
*** Deploying v56.0 metadata with SOAP API v53.0 connection ***
Deploy ID: 0AfDn00000BER8bKAH
DEPLOY PROGRESS | ████████████████████████████████████████ | 2/2 Components

=== Component Failures [1]
Type   Name                  Problem
─────  ────────────────────  ─────────────────────────────────────────────
Error  Contact.B2C_Commerce  SortOrder must be in sequential order from 1.

ERROR running force:source:deploy:  Deploy failed.