# - #4 : the developer version. The 4th number is the database subversion.
# used by developers when the database changes. updatedatabase take care of the changes itself
# and is automatically called by Auth.pm when needed.
-$VERSION = "3.21.00.016";
+$VERSION = "3.21.00.017";
sub version {
return $VERSION;
+++ /dev/null
--- table adjustments for uploaded_files
-ALTER TABLE uploaded_files
- CHANGE COLUMN id hashvalue char(40) NOT NULL,
- DROP PRIMARY KEY;
-ALTER TABLE uploaded_files
- ADD COLUMN id int NOT NULL AUTO_INCREMENT FIRST,
- ADD CONSTRAINT PRIMARY KEY (id),
- ADD COLUMN filesize int,
- ADD COLUMN dtcreated timestamp,
- ADD COLUMN categorycode tinytext,
- ADD COLUMN owner int;
SetVersion($DBversion);
}
-$DBversion = "XXX";
+$DBversion = "3.21.00.017";
if ( CheckVersion($DBversion) ) {
$dbh->do("
CREATE TABLE uploaded_files (
- id CHAR(40) NOT NULL PRIMARY KEY,
+ id int(11) NOT NULL AUTO_INCREMENT,
+ hashvalue CHAR(40) NOT NULL,
filename TEXT NOT NULL,
- dir TEXT NOT NULL
- ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+ dir TEXT NOT NULL,
+ filesize int(11),
+ dtcreated timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
+ categorycode tinytext,
+ owner int(11),
+ PRIMARY KEY (id)
+ ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci
");
print "Upgrade to $DBversion done (Bug 6874: New cataloging plugin upload.pl)\n";