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

upgade v2.0 is_primary email, phone, im, address

    Details

    • Type: Bug
    • Status: Done/Fixed
    • Priority: Major
    • Resolution: Fixed/Completed
    • Affects Version/s: 2.0
    • Fix Version/s: None
    • Component/s: Core CiviCRM
    • Labels:
      None

      Description

      the location.mysql script run during the schema upgrade process modifies the civicrm_email table by a set to the depreciated civicrm_location table. This process will set all emails for a specific contact to the first value of civicrm_location.is_primary it finds as shown below

      – * Update email data/values

      UPDATE civicrm_email ce, civicrm_location cl

      SET
      ce.contact_id = cl.entity_id,
      ce.location_type_id = cl.location_type_id,
      ce.is_primary = cl.is_primary

      WHERE cl.id = ce.location_id AND cl.entity_table = 'civicrm_contact';
      ----------------------------------------------------------------------------------------------

      The same logic is used for IM, address and phone.

        Attachments

          Activity

            People

            • Assignee:
              deepak Deepak Srivastava
              Reporter:
              speleo Henry Bennett
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: