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

Logic which matches users to contacts is not considering contact type (may link user to organization)

    Details

    • Type: Bug
    • Status: Done/Fixed
    • Priority: Trivial
    • Resolution: Fixed/Completed
    • Affects Version/s: 3.4.3, 4.0.3
    • Fix Version/s: 3.4.4, 4.0.4
    • Component/s: None
    • Labels:
      None

      Description

      It appears that the code which inserts uf_match records is ignoring contact type while matching on email addresses. I am able to replicate item 1 below - using these steps:

      1. create user with email = info@civicrm.org
      2. create Organization with email = info@civicrm.org
      3. create Individual with email = info@civicrm.org
      4. Run Synch Users to Contacts (from Admin > Manage)

      Expected behavior - user is "linked" to the individual contact record.
      Actual behavior - user is "linked" to the organization record.

      I tried to recreate the second item below, but in my testing the registering user was linked to the Individual record with the matching email address as expected.

      — original post from Jim Taylor -------------
      The issue or Org being confused for Individuals is not just with Events but seemingly with the Drupal/CiviCRM sync script and Drupal User Registration. Two scenarios where we are seeing Drupal accounts linked to CiviCRM Organizations. In both cases an Organization and Individual contact have the same e-mail and the Organization's Contact ID is lower than that of the Individual.

      1.) Running the User/Contact sync CiviCRM will link the Drupal account with the Org account.

      2.) A person creates a user account through Drupal and uses and e-mail already in CiviCRM in an Organization's account the new Drupal account will be linked to the Organization's account.

        Attachments

          Activity

            People

            • Assignee:
              yashodha Yashodha Chaku
              Reporter:
              dgg David Greenberg
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: