The snippets below show the duplicate contacts, the webform CiviCRM tab, and the matching rules. If I fill in name & a matching email the form updates the contact, does not create a dup. If I supply name & a matching phone the duplicate shows up. The Civi and Drupal logs don't show anything related. Thoughts?

Civi v5.24.3, Drupal v7.69, PHP v7.1.14, MySQL v5.6.41-84.1, Webform v7.x-4.22, Webform CiviCRM v7.x-4.28.

Duplicate contacts

Webform CiviCRM tab

Matching rules

Default Unsupervised matching rule for Individual

  • i) Is this dedupe rule working on your front end - CiviCRM native pages? Webform CiviCRM just uses CiviCRM APIs. ii) upgrade to 7.x-5.x - we have replaced some leftover direct queries with APIs, not sure if dedupe was one of them iii) I've never used Phone # in a dedupe rule as users can enter their digits in so many ways, with and without (), -, +1, so many options. I know you're testing and matching it here - but even if you get it working - it will be tough to make it useful. iii) then there are all the type and location id-s on phone numbers. This makes for a really complicated dedupe rule May 15, 2020 at 13:08
  • PS - upvote for the great screenshots! May 15, 2020 at 13:10
  • Glad the screenshots help! Updated webform_civicrm to 7.x-5.0 with the same duplicate results. If you meant 7.x-5.x-dev let me know and I'll try that too. If I "Use Rule" in CiviCRM's Find and Merge Duplicate Contacts this pair of duplicates is called out as expected. I was curious whether the match would be based on the string or on something deeper, i.e. civicrm_phone.phone_numeric in the dB. In any case, my numbers are all in Florida and I can force the input to 10 digits. Many of the parents we work with don't use email so we're transitioning to rely on mobile phones instead.
    – wil_SRQ
    May 15, 2020 at 18:01
  • No - not -dev - just 7.x-5.x brach is ok. There have been recent fixes to the dedupe API in CiviCRM core that related to numbers (dob) and also custom fields. Have you tried creating a profile with these fields and fill it out (while logged out) so you can test your unsupervised dedupe rule? May 15, 2020 at 18:55
  • No, I've never used profiles. But this got much scarier now. I have another CiviCRM site and a test form there performs perfectly. So something is broken in the first site and I have no idea where to start looking :-(
    – wil_SRQ
    May 15, 2020 at 22:49

1 Answer 1


Per Karin's advice, filed bug report on Core - https://lab.civicrm.org/dev/core/-/issues/1767. Filed a separate one for webform_civicrm - https://www.drupal.org/project/webform_civicrm/issues/3137284. Both are needed for our use case. I proposed patches with each issue, should anyone else run into this before it is fixed properly. BTW, good to know that the phone match is based on digits only. All formatting & decorations are stripped off.

  • Nice - well done - 👍 May 16, 2020 at 21:04
  • Sorry @KarinG-SemperIT, had to patch webform_civicrm as well 😥
    – wil_SRQ
    May 16, 2020 at 21:50
  • No problem - happy you managed to work through it! We'll do some thinking to see which way we should go on this. May 16, 2020 at 23:49

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.