[drupal-devel] [bug] Move node revision information for files to a
separate table
Junyor
drupal-devel at drupal.org
Sun Sep 18 19:21:10 UTC 2005
Issue status update for
http://drupal.org/node/31354
Post a follow up:
http://drupal.org/project/comments/add/31354
Project: Drupal
Version: cvs
Component: file system
Category: bug reports
Priority: normal
Assigned to: Anonymous
Reported by: Souvent22
Updated by: Junyor
Status: patch (code needs review)
Attachment: http://drupal.org/files/issues/drupal-head.file-revisions3.junyor.patch (8.73 KB)
Updates after code review from Cvbge (thanks!):
- fixed typo in database.pgsql
- using a select statement in update_148()
- fixed logic in upload_delete()
Junyor
Previous comments:
------------------------------------------------------------------------
Fri, 16 Sep 2005 00:55:42 +0000 : Souvent22
I think that the files table has too much redundat data in it since we
now have the new revisions system. I think another table to link
revisions to files would be more appropriate.
------------------------------------------------------------------------
Fri, 16 Sep 2005 14:17:55 +0000 : Junyor
I agree. NID and VID should be removed, making a new table containing
FID, NID, and VID with all three as keys.
------------------------------------------------------------------------
Sun, 18 Sep 2005 09:56:50 +0000 : Junyor
Attachment: http://drupal.org/files/issues/drupal-head.file-revisions.junyor.patch (8.27 KB)
Here's a patch with the proposed changes. This is completely untested.
I don't know SQL very well, so I'm sure I've done something wrong. I'll
hopefully be able to do testing later today.
------------------------------------------------------------------------
Sun, 18 Sep 2005 17:04:38 +0000 : Junyor
Attachment: http://drupal.org/files/issues/drupal-head.file-revisions2.junyor.patch (8.55 KB)
Updated patch:
- cleaned up errors in database.*
- cleaned up errors in update.inc
I tested adding files, listing and unlisting files, deleting files,
deleting revisions, deleting nodes, adding files only to certain
revisions, etc. Deleting revisions does not delete the files, but as
far as I can tell, that's because of http://drupal.org/node/31323.
More information about the drupal-devel
mailing list