• SY Chan 7
  • NEWBIE
  • 0 Points
  • Member since 2016

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 1
    Likes Given
  • 0
    Questions
  • 2
    Replies
i am getting this error while logging through username and password through login.salesforce.com.But iam able to login into the application through SSO .
Hi 
I managed to find out how to pass this bug so I give you the clue that can help.

Problem
- I have defined a duplicate rule with some conditions, especially a condition on the Account recordtype. The rule works fine on the sandbox.
- I want to migrate it to another org that have the exact same Account recordtypes.

With changeset : the validation fails with error "Field: bad value for restricted picklist field: RecordTypeId"
With Ant Migration tool : the import fails with the same error!

I managed finally after a while to import it with Ant by manually modifying the xml file as this:
Xml file exported with ant retrieve contains:

        <duplicateRuleFilterItems>
            <field>RecordTypeId</field>
            <operation>notEqual</operation>
            <value>ADD Address</value>
            <sortOrder>2</sortOrder>
            <table>Account</table>
        </duplicateRuleFilterItems>

modified as:
        <duplicateRuleFilterItems>
            <field>RecordType</field>     <= NOT THE ID!
            <operation>notEqual</operation>
            <value>ADD Address</value>
            <sortOrder>2</sortOrder>
            <table>Account</table>
        </duplicateRuleFilterItems>        
        
I tried with API versions 40 and below.

So the Ant export and import of the xml file don't respect the same specification! Same with Changesets.
I call that a bug, surprised also that it's not yet mentionned in some other posts.

Hope this helps,
regards
Hi 
I managed to find out how to pass this bug so I give you the clue that can help.

Problem
- I have defined a duplicate rule with some conditions, especially a condition on the Account recordtype. The rule works fine on the sandbox.
- I want to migrate it to another org that have the exact same Account recordtypes.

With changeset : the validation fails with error "Field: bad value for restricted picklist field: RecordTypeId"
With Ant Migration tool : the import fails with the same error!

I managed finally after a while to import it with Ant by manually modifying the xml file as this:
Xml file exported with ant retrieve contains:

        <duplicateRuleFilterItems>
            <field>RecordTypeId</field>
            <operation>notEqual</operation>
            <value>ADD Address</value>
            <sortOrder>2</sortOrder>
            <table>Account</table>
        </duplicateRuleFilterItems>

modified as:
        <duplicateRuleFilterItems>
            <field>RecordType</field>     <= NOT THE ID!
            <operation>notEqual</operation>
            <value>ADD Address</value>
            <sortOrder>2</sortOrder>
            <table>Account</table>
        </duplicateRuleFilterItems>        
        
I tried with API versions 40 and below.

So the Ant export and import of the xml file don't respect the same specification! Same with Changesets.
I call that a bug, surprised also that it's not yet mentionned in some other posts.

Hope this helps,
regards