Answers.Body: <p>Not deleting financial information when a registration is deleted is by design so that organizations can pass audits. One wouldn't want an employee to delete some registrants and pocket the money if there is no checkin at the event, for example. </p>
  
  <p>If you would like to sponsor an extension to optionally change this behaviour it should be fairly simple to create, depending on how you want to approach things.</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-02-09T08:25:57.033Z
Answers.Text: Thanks for your explanation. I got the point on not deleting financial information. But if you delete some Participants with a contibution, and then make an advanced search, the results will not match with the report results. So that's why i was wondering if we can't unify this two different behaviour.
Answers.UserDisplayName: Albert V
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-02-09T19:50:20.660Z
Answers.Text: @AlbertV agreed that it would be ideal if things matched between the different contexts. But I think the intent is take account of the purpose of those contexts - one about money, one about finding all the participants - when determining the results.
Answers.UserDisplayName: Joe Murray
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-02-07T21:59:40.950Z
Answers.LastActivityDate: 2017-02-07T21:59:40.950Z
Answers.UserDisplayName: Joe Murray
Body: <p>At Event Income Report (both Detail and Summary), in the results, contacts deleted with contributions are counted.</p>
  
  <p>I tested it in dmaster and have the same behavior.</p>
  
  <p>Obviously, it's because in the SQL sentence it doesn't appear the contact.is_deleted = 0 in the where clause.</p>
  
  <p>The reason for that behavior is that CiviCRM considers still valid deleted contacts contributions and refuses to delete them.</p>
  
  <p>So, what do you think? It's a bug that needs to be fixed? Create a custom Report? An extension?</p>
  
  <p>Thanks for answering!</p>
  
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-02-02T12:42:06.677Z
Comments.Text: I haven't checked the code, but "is_deleted = 0" can also be added by ACL clauses. (just to keep in mind if debugging this or comparing with other reports)
Comments.UserDisplayName: bgm
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-02-08T05:28:30.957Z
Comments.Text: i edited this hopefully to make it clearer this is about deleted Participants, not deleted Contacts.
Comments.UserDisplayName: petednz - fuzion
Tags: <civievent><civireport><deleted>
Title: Should deleted Participant contributions appear in the report Event Income Report?
ThreadText: # Should deleted Participant contributions appear in the report Event Income Report?
  
  (Asked by: username_0 on 2017-02-02)
  
  At Event Income Report (both Detail and Summary), in the results, contacts deleted with contributions are counted.
  
  I tested it in dmaster and have the same behavior.
  
  Obviously, it's because in the SQL sentence it doesn't appear the contact.is\_deleted = 0 in the where clause.
  
  The reason for that behavior is that CiviCRM considers still valid deleted contacts contributions and refuses to delete them.
  
  So, what do you think? It's a bug that needs to be fixed? Create a custom Report? An extension?
  
  Thanks for answering!
  
  **Tags:** civievent, civireport, deleted
  
  > **Comments:**
  > **username_1**: I haven't checked the code, but "is_deleted = 0" can also be added by ACL clauses. (just to keep in mind if debugging this or comparing with other reports)  
  > **username_2**: i edited this hopefully to make it clearer this is about deleted Participants, not deleted Contacts.  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_3 on 2017-02-07. Score: 2 | Accepted answer
  
  Not deleting financial information when a registration is deleted is by design so that organizations can pass audits. One wouldn't want an employee to delete some registrants and pocket the money if there is no checkin at the event, for example.
  
  If you would like to sponsor an extension to optionally change this behaviour it should be fairly simple to create, depending on how you want to approach things.
  
  > **Comments:**
  > **username_0**: Thanks for your explanation. I got the point on not deleting financial information. But if you delete some Participants with a contibution, and then make an advanced search, the results will not match with the report results. So that's why i was wondering if we can't unify this two different behaviour.  
  > **username_3**: @AlbertV agreed that it would be ideal if things matched between the different contexts. But I think the intent is take account of the purpose of those contexts - one about money, one about finding all the participants - when determining the results.  
  
  ---
  
  