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

run job.disable_expired_relationships in one query

    Details

    • Type: Improvement
    • Status: Won't Do
    • Priority: Trivial
    • Resolution: Won't Do
    • Affects Version/s: 4.6.5
    • Fix Version/s: Unscheduled
    • Component/s: None
    • Labels:
      None
    • Versioning Impact:
      Patch (backwards-compatible bug fixes)
    • Documentation Required?:
      None
    • Funding Source:
      Needs Funding

      Description

      We are (still ) migrating a large database (+/- 1 million relationships) to CiviCRM. Now after the migration, we want to run job.disable_expired_relationships to change the status of all imported relationships with end_date in the past to inactive.

      This seemed to cause a timeout; about 900000 of the relationships need to be updated.

      Instead of updating the records one by one, I now update all the records using an update statement.

      See: https://forum.civicrm.org/index.php/topic,36594.msg155432.html

      PR at https://github.com/civicrm/civicrm-core/pull/6322

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              mallezie Tim Mallezie
            • Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: