Uploaded image for project: 'CiviCRM'
  1. CiviCRM
  2. CRM-11867

Clarify matching rules for reserved optimized rules

    Details

    • Type: Task
    • Status: Done/Fixed
    • Priority: Trivial
    • Resolution: Fixed/Completed
    • Affects Version/s: 4.3.0
    • Fix Version/s: 4.3.0
    • Component/s: None
    • Labels:
      None

      Description

      With the UI changes in CRM-10885, we now have 3 reserved optimized rules for Individual dupe matching. These 3 rules use hard-coded queries (CRM_Dedupe_BAO_QueryBuilder_IndividualGeneral, CRM_Dedupe_BAO_QueryBuilder_IndividualUnsupervised, CRM_Dedupe_BAO_QueryBuilder_IndividualSupervised), rather than the fields in civicrm_dedupe_rule.

      To prevent confusion, modify the form template for editing dedupe rules and hide the fields table for these 3 special rules. Replace it with text explaining the matching rules used.

      — Original Post —
      I noticed some oddities when working on WebTest_Contact_MergeContactsTest. After fixing a lot of issues with the test, it remains broken because it attempts to modify a reserved dedupe rule, which is no longer allowed. Not sure what to do about that, but...
      Since they are now set in stone I looked at our reserved rules:

      Name and Email (reserved)
      First Name: 5
      Last Name: 7
      Email: 10
      Threshold: 20

      This doesn't make sense to me - this rule is supposed to be for "supervised" use yet it is not the least bit fuzzy. A threshold of 20 means all 3 fields need to be exact matches. (it's also silly that the numbers don't add up)

      Name and Address (reserved)
      First Name: 5
      Last Name: 5
      Address: 5
      Middle Name: 1
      Individual Suffix: 1
      Threshold: 15

      Again the numbers don't add up, again it's not at all fuzzy (this one says it's for "general" use). And the last two fields are basically lame ducks since they don't have enough weight to make any difference.

      Could anyone explain the purpose of these 2 rules?

      Also, since the webtest was attempting to edit these rules that tells us that
      1) these rules pre-date 4.3
      2) editing them was fairly common
      How does our upgrade script handle that? Will it revert the admin's changes (bad), or freeze the rules with the changes (also bad). I'm hoping it will do the right thing and create new reserved rules and leave the user-edited ones alone, but wanted to check.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                ravish.nair Ravish Nair
                Reporter:
                colemanw Coleman Watts
              • Votes:
                0 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: