Answers.Body: <p>By default the Webform-CiviCRM module uses the default "Unsupervised" rule from CiviCRM to determine if an unknown contact is already in your database. If this is not happening for you, check your rule's criteria.</p>
  
  <p>And as of v4.11 you can now <a href="https://www.drupal.org/node/1378900" rel="nofollow noreferrer">specify the matching rule per contact</a>.</p>
  
  <p>You'll find this new option just under the "Contact Fields":</p>
  
  <p><img src="https://i.sstatic.net/ATCXj.png" alt="enter image description here"></p>
  
  <p>The help text says:</p>
  
  <blockquote>
    <p>This determines how an unknown contact will be handled when the
    webform is submitted.</p>
    
    <ul>
    <li>Select the "Default Unsupervised" rule for the
    same duplicate matching used by CiviCRM event registration &amp;
    contribution forms.</li>
    <li>Select a specific rule to customize how matching
    is performed.</li>
    <li>Or select "- None -" to always create a new contact.</li>
    </ul>
    
    <p>Note: Matching rules are only used if the contact is not already
    selected via "Existing Contact" field.</p>
  </blockquote>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2015-07-07T12:58:35.137Z
Answers.Text: I have a previous version of CiviCRM that does not have the option of choosing the 'Matching Rule'. If I'm correct, this should not be an issue as the webform should just use whatever default dedup rule CiviCRM uses as the unsupervised rule. Is this correct?
  
  This still is not working if the Drupal account was created after the CiviCRM account (as I explained in my edit of my original post). It only seems to work if the Drupal account and the CiviCRM contact or 'linked'.
Answers.UserDisplayName: spinsheet
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2015-07-07T14:05:34.327Z
Answers.Text: What are the criteria of your default unsupervised rule?
Answers.UserDisplayName: Coleman
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2015-07-07T14:33:37.367Z
Answers.Text: First name: 6, Last name: 3, Email: 4, Street address (First four characters): 1. The total for a match is 10. When I run this dedupe rule it does find the duplicates so the rule's working. It's just doesn't seem to be run when the form is submitted.
Answers.UserDisplayName: spinsheet
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2015-07-08T16:51:23.347Z
Answers.Text: Let me clarify that. It seems to run with the form is submitted by a user who's Drupal account was created before the CiviCRM contact record. If the user creates a Drupal account and fills out the form and there was a preexisting CiviCRM contact record that matches the dedup rule it acts as if the rule was never run as a duplicate is created.
Answers.UserDisplayName: spinsheet
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2015-06-05T21:23:26.660Z
Answers.LastActivityDate: 2015-07-08T18:05:33.490Z
Answers.LastEditDate: 2015-07-08T18:05:33.490Z
Answers.UserDisplayName: Coleman
Answers.Body: <p>When you add the contact in the CiviCRM tab of the Webform, making sure you check the "Existing Contact" box:</p>
  
  <p><img src="https://i.sstatic.net/pTNC2.jpg" alt="Existing contact"></p>
  
  <p>From the help:</p>
  
  <blockquote>
    <p>Gives many options for how this contact can be autofilled or selected.
    From the Webform tab you can edit this field to configure:</p>
    
    <ul>
    <li>Widget: Determine whether to expose this field to the form as an
    autocomplete or select element, or hide it and pick the contact
    automatically.</li>
    <li>Default Value: Select a contact based on the current
    user, relationships, or other options.</li>
    <li>Filters: Limit the list of
    available choices from which this contact may be autofilled or
    selected.</li>
    <li>Show/Hide Fields: Control which other fields the user is
    allowed to edit and which will be hidden.</li>
    </ul>
  </blockquote>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2015-06-08T14:46:01.790Z
Answers.Text: Seems that I had a bad rule which is why I was having this issue.
Answers.UserDisplayName: spinsheet
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2015-07-06T16:45:18.407Z
Answers.Text: I still seem to be having issues with duplicates being created. I edited my original post with the details. Any thoughts on what I might be doing wrong?
Answers.UserDisplayName: spinsheet
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2015-07-06T20:13:07.590Z
Answers.Text: You don't seem to have commented on Colemans answer below where he explains how to set the Matching Rule.
Answers.UserDisplayName: petednz - fuzion
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2015-07-07T13:00:43.133Z
Answers.Text: I just commented but I really don't think that's the issue as the webform should default to whatever CiviCRM uses as the unsupervised rule for deduping. Coleman's response, it seems to me, would just allow me to choose a different rule for that webform.
Answers.UserDisplayName: spinsheet
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2015-06-05T20:35:36.997Z
Answers.LastActivityDate: 2015-06-05T20:35:36.997Z
Answers.UserDisplayName: Laryn
Body: <p>On the CiviCRM profiles you have the ability to set it update matching contact. I don't see this functionality with the Drupal webform CiviCRM Integration module. Is it there and I'm simply missing it? When I log in and fill out the form it simply creates a duplicate contact if that contact already exists. I would like to update the existing contact instead. Is this possible?</p>
  
  <p>I still seem to be having an issue with duplicates being created. The unsupervised rule is set as such: </p>
  
  <ul>
  <li>First name: 6</li>
  <li>Last name: 3</li>
  <li>Email: 4</li>
  <li>Street address (First four characters): 1</li>
  <li>The total for a match is 10</li>
  </ul>
  
  <p>I had a contact in CiviCRM 'Janice Anderson' who did not have an associated Drupal account. Janice created a Drupal account and then went to the form and filled out the information on the webfrom and when she submitted the form it created a duplicate CiviCRM contact instead of merging what she was filling out and the existing contact.</p>
  
  <p>I then ran the dedup rule and it found the two (the old one and the newly created one) CiviCRM contacts and stated that the total was 13. So CiviCRM knew they were possible duplicates based on the rule but it still did not merge them at from submission.</p>
  
  <p>This seems to only be happening if the user is currently in CiviCRM and there is not an associated Drupal account for that user. I just tested by creating a CiviCRM user (Jon Doe, jon.doe@mydomain.com). I then created a Drupal account using that same email address and went to the webform and added the same first name, last name, and email address. CiviCRM created a duplicate contact. If I create the Drupal account first then use the webform it creates a CiviCRM contact. If I then go back to the webform while logged in and update information it updates the contact correctly without creating a duplicate.</p>
  
  <p>Is this action to be expected or am I missing a setting somewhere?</p>
  
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2015-07-21T15:39:09.177Z
Comments.Text: Is anyone else having this same issue? Shouldn't the webform use CiviCRM's default unsupervised dedup rule whether the user's Drupal user account was created before or after the CiviCRM contact was created?
  
  If the there is a CiviCRM contact already created and the user then creates a Drupal user account then fills in the webform with matching information CiviCRM won't merge the two contacts, it creates a new one.
Comments.UserDisplayName: spinsheet
Tags: <drupal><webform-civicrm><duplicate-contacts>
Title: Can Drupal Webform Integration update matching contacts
ThreadText: # Can Drupal Webform Integration update matching contacts
  
  (Asked by: username_0 on 2015-06-05)
  
  On the CiviCRM profiles you have the ability to set it update matching contact. I don't see this functionality with the Drupal webform CiviCRM Integration module. Is it there and I'm simply missing it? When I log in and fill out the form it simply creates a duplicate contact if that contact already exists. I would like to update the existing contact instead. Is this possible?
  
  I still seem to be having an issue with duplicates being created. The unsupervised rule is set as such:
  
  * First name: 6
  * Last name: 3
  * Email: 4
  * Street address (First four characters): 1
  * The total for a match is 10
  
  I had a contact in CiviCRM 'Janice Anderson' who did not have an associated Drupal account. Janice created a Drupal account and then went to the form and filled out the information on the webfrom and when she submitted the form it created a duplicate CiviCRM contact instead of merging what she was filling out and the existing contact.
  
  I then ran the dedup rule and it found the two (the old one and the newly created one) CiviCRM contacts and stated that the total was 13. So CiviCRM knew they were possible duplicates based on the rule but it still did not merge them at from submission.
  
  This seems to only be happening if the user is currently in CiviCRM and there is not an associated Drupal account for that user. I just tested by creating a CiviCRM user (Jon Doe, jon.doe@mydomain.com). I then created a Drupal account using that same email address and went to the webform and added the same first name, last name, and email address. CiviCRM created a duplicate contact. If I create the Drupal account first then use the webform it creates a CiviCRM contact. If I then go back to the webform while logged in and update information it updates the contact correctly without creating a duplicate.
  
  Is this action to be expected or am I missing a setting somewhere?
  
  **Tags:** drupal, webform-civicrm, duplicate-contacts
  
  > **Comments:**
  > **username_0**: Is anyone else having this same issue? Shouldn't the webform use CiviCRM's default unsupervised dedup rule whether the user's Drupal user account was created before or after the CiviCRM contact was created?  If the there is a CiviCRM contact already created and the user then creates a Drupal user account then fills in the webform with matching information CiviCRM won't merge the two contacts, it creates a new one.  
  
  ---
  
  ## 2 answers
  
  ### Answer by username_2 on 2015-06-05. Score: 6 | Accepted answer
  
  When you add the contact in the CiviCRM tab of the Webform, making sure you check the "Existing Contact" box:
  
  ![Existing contact](https://i.sstatic.net/pTNC2.jpg)
  
  From the help:
  
  > Gives many options for how this contact can be autofilled or selected.
  > From the Webform tab you can edit this field to configure:
  >
  > * Widget: Determine whether to expose this field to the form as an
  >   autocomplete or select element, or hide it and pick the contact
  >   automatically.
  > * Default Value: Select a contact based on the current
  >   user, relationships, or other options.
  > * Filters: Limit the list of
  >   available choices from which this contact may be autofilled or
  >   selected.
  > * Show/Hide Fields: Control which other fields the user is
  >   allowed to edit and which will be hidden.
  
  > **Comments:**
  > **username_0**: Seems that I had a bad rule which is why I was having this issue.  
  > **username_0**: I still seem to be having issues with duplicates being created. I edited my original post with the details. Any thoughts on what I might be doing wrong?  
  > **username_3**: You don't seem to have commented on username_1s answer below where he explains how to set the Matching Rule.  
  > **username_0**: I just commented but I really don't think that's the issue as the webform should default to whatever CiviCRM uses as the unsupervised rule for deduping. username_1's response, it seems to me, would just allow me to choose a different rule for that webform.  
  
  ---
  
  ### Answer by username_1 on 2015-06-05. Score: 10
  
  By default the Webform-CiviCRM module uses the default "Unsupervised" rule from CiviCRM to determine if an unknown contact is already in your database. If this is not happening for you, check your rule's criteria.
  
  And as of v4.11 you can now [specify the matching rule per contact](https://www.drupal.org/node/1378900).
  
  You'll find this new option just under the "Contact Fields":
  
  ![enter image description here](https://i.sstatic.net/ATCXj.png)
  
  The help text says:
  
  > This determines how an unknown contact will be handled when the
  > webform is submitted.
  >
  > * Select the "Default Unsupervised" rule for the
  >   same duplicate matching used by CiviCRM event registration &
  >   contribution forms.
  > * Select a specific rule to customize how matching
  >   is performed.
  > * Or select "- None -" to always create a new contact.
  >
  > Note: Matching rules are only used if the contact is not already
  > selected via "Existing Contact" field.
  
  > **Comments:**
  > **username_0**: I have a previous version of CiviCRM that does not have the option of choosing the 'Matching Rule'. If I'm correct, this should not be an issue as the webform should just use whatever default dedup rule CiviCRM uses as the unsupervised rule. Is this correct?  This still is not working if the Drupal account was created after the CiviCRM account (as I explained in my edit of my original post). It only seems to work if the Drupal account and the CiviCRM contact or 'linked'.  
  > **username_1**: What are the criteria of your default unsupervised rule?  
  > **username_0**: First name: 6, Last name: 3, Email: 4, Street address (First four characters): 1. The total for a match is 10. When I run this dedupe rule it does find the duplicates so the rule's working. It's just doesn't seem to be run when the form is submitted.  
  > **username_0**: Let me clarify that. It seems to run with the form is submitted by a user who's Drupal account was created before the CiviCRM contact record. If the user creates a Drupal account and fills out the form and there was a preexisting CiviCRM contact record that matches the dedup rule it acts as if the rule was never run as a duplicate is created.  
  
  ---
  
  