We noticed that at some point, the CiviDiscount reports for number of times a code has been used is reporting duplicates: i.e. for every one transaction that is made using a discount code, the code is being reported as having been used twice. So a user with one transaction will show up twice in the report. The only exception to this per code are transactions that were processed by a staff user though the back end.

Note: this is not happening with all codes but there seems to be no consistency or discernible different between affected codes and non-affected codes. I checked the fields in MySQL to see if it was an issue with the display or the way the data is being recorded and the each duplicate is separate, distinct records in mysql. This is only happening with codes where a financial exchange happens, but not if the discount is 100%.

In the screenshot below, you can see that there were two separate records of a discount being used for one user who only has one recorded transaction. The records are 3 seconds apart.

enter image description here

CiviCRM 5.3.1 and CiviDiscount 3.5.

Edit: We are now on 5.4.0 and the problem is still occurring.

Edit2: We are now on 5.11.0 and CiviDiscount 3.7 and the problem is occurring again.

  • I noticed that the affected codes (or at least some) had a $sign in the discount amount field. I removed that and we'll see if it solves the problem! – Christia Oct 3 '18 at 18:17
  • We have a client on 5.6.1 and CiviDiscount 3.6, and this is occurring for them. There is no $sign in the discount amount field and it is not occurring consistently on every transaction. There doesn't seem to be a rhyme or reason to it. – Lesley Carter - BackOffice Feb 5 '19 at 14:24
  • I think the dollar sign fixed it for us but have you tried upgrading the extension? 3.7 is available now. – Christia Feb 5 '19 at 14:30
  • 3.7 is only stable for CiviCRM 5.8, so that's not an option just yet. Thanks for responding so quickly! – Lesley Carter - BackOffice Feb 6 '19 at 15:05
  • I'm having this issue again. I will post an answer if I ever figure it out! – Christia Apr 15 '19 at 4:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.