Question about 'donor_id' from _jd_field_value table

  • Dave
  • Topic Author
  • Offline
  • Senior Member
  • Senior Member
More
2 months 3 weeks ago #164124 by Dave
The _jd_donors table has 'id'.
'id' is auto_increment.
"id' will increment each time a record is written to the table, regardless of whether the transaction fails or is canceled. 
If a rollback occurs due to transaction fail or cancel, 'id' does not decrement.

The _jd_field_value table has 'donor_id'.
What are the conditions for incrementing 'donor_id'?
Will 'donor_id' increment if a transaction fails or is canceled?

Basis: I want to use 'donor_id' as a sequential Member Number for each successful donor. 
If it works correctly, the most recent Member Number should always match the total NumberDonors.
In other words, 'donor_id' should only increment for successful transactions. It should not increment for failed or cancelled transactions.

Is this how 'donor_id' works in JoomDonation?

Thanks.

Please Log in or Create an account to join the conversation.

More
2 months 3 weeks ago #164145 by Mr. Dam
Hi Dave,
donor_id in table #__jd_field_values is id in table #__jd_donors.
Joom Donation will use ID in table #__jd_donors to update into the records in table #__jd_field_values
Thanks
Dam

Please Log in or Create an account to join the conversation.

  • Dave
  • Topic Author
  • Offline
  • Senior Member
  • Senior Member
More
2 months 3 weeks ago #164149 by Dave
OK.

Then I need to pay for custom work.

I will start a ticket.

Thanks.

Please Log in or Create an account to join the conversation.

Moderators: Mr. DamDũng Nguyễn Việt