Requests for comment/Page deletion/Proposed solution

Leucosticte proposes the following changes.

Principles
Each  and   can exist in either   or   or both.

Details

 * Add  table, which has three fields,  ,   , and.
 * When a page is deleted:
 * Its entry will be inserted into the  table
 * Its entry will be deleted from the  table
 * All revisions will have  (16) added to the current value of.


 * When revisions from a page are undeleted:
 * Its entry will be inserted into the  table, with the same   it originally had (stored in  )
 * Its entry will be deleted from the  table
 * All undeleted revision will have  (16) subtracted from the current value of.


 * When a page is created, if there is an entry with that same page title and namespace in the  table, then:
 * The page will be created with that dp_id as page_id
 * Its entry will be deleted from the  table


 * When a page is moved to a page title and namespace that exist in the  table:
 * Nothing changes in