CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviMember (Moderator: Deepak Srivastava) »
  • UpdateMembershipRecord.php added lot of records in civicrm_membership_log
Pages: [1]

Author Topic: UpdateMembershipRecord.php added lot of records in civicrm_membership_log  (Read 964 times)

ruid

  • I post occasionally
  • **
  • Posts: 46
  • Karma: 4
UpdateMembershipRecord.php added lot of records in civicrm_membership_log
September 28, 2009, 07:09:27 pm
There are many records have been added to civicrm_membership_log every time after running the UpdateMembershipRecord.php.
However, most of them didn't change. It looks like keep adding same logs to a membership. Is it right?

This made my database getting bigger. I am wondering if it can only add records to when membership has been updated.

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: UpdateMembershipRecord.php added lot of records in civicrm_membership_log
September 28, 2009, 08:39:32 pm

can you confirm that this is an issue with 3.0? I'd be surprised if we add a membership log entry for every member even if we dont update it. I dont think that code is very efficient, but i do think it updates only memberships that meet the criteria

all log tables need to be pruned periodically. we currently dont have good processes for this

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

ruid

  • I post occasionally
  • **
  • Posts: 46
  • Karma: 4
Re: UpdateMembershipRecord.php added lot of records in civicrm_membership_log
September 28, 2009, 11:53:12 pm
It is 2.2.x version. I did a little modification on this UpdateMembershipRecord.php file. Although I don't think it will cause this problem, I am willing to look it deeper.

What I have changed is:
Code: [Select]
89 +  AND civicrm_membership.status_id  !=6
We don't need to check this status so less memberships will be returned.

Thanks Lobo.

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviMember (Moderator: Deepak Srivastava) »
  • UpdateMembershipRecord.php added lot of records in civicrm_membership_log

This forum was archived on 2017-11-26.