Bug 8312 - Bug 1633 causes an error when upgrading the database
Summary: Bug 1633 causes an error when upgrading the database
Status: CLOSED INVALID
Alias: None
Product: Koha
Classification: Unclassified
Component: OPAC (show other bugs)
Version: 3.8
Hardware: All All
: P5 - low major
Assignee: Owen Leonard
QA Contact:
URL:
Keywords:
Depends on: 1633
Blocks:
  Show dependency treegraph
 
Reported: 2012-06-25 17:13 UTC by Robin Sheat
Modified: 2014-12-07 20:02 UTC (History)
1 user (show)

See Also:
GIT URL:
Change sponsored?: ---
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Robin Sheat 2012-06-25 17:13:55 UTC
This causes an error on upgrade:

[Tue Jun 26 04:58:51 2012] updatedatabase.pl: DBD::mysql::db do failed: Can't create table 'koha_central.biblioimages' (errno: 150) at /home/robin/kohaclones/ca/installer/data/mysql/updatedatabase.pl line 4634.

This SQL:

       CREATE TABLE `biblioimages` (
          `imagenumber` int(11) NOT NULL AUTO_INCREMENT,
          `biblionumber` int(11) NOT NULL,
          `mimetype` varchar(15) NOT NULL,      
          `imagefile` mediumblob NOT NULL, 
          `thumbnail` mediumblob NOT NULL,
          PRIMARY KEY (`imagenumber`),
          CONSTRAINT `bibliocoverimage_fk1` FOREIGN KEY (`biblionumber`) REFERENCES `biblio` (`biblionumber`) ON DELETE CASCADE ON UPDATE CASCADE
          ) ENGINE=InnoDB DEFAULT CHARSET=utf8

doesn't work unless everything after 'ENGINE' is ommitted.
Comment 1 Robin Sheat 2012-06-25 17:20:27 UTC
This seems to be because the biblio table on my database is MyISAM, and so forcing it to InnoDB causes breakage.
Comment 2 Robin Sheat 2012-06-25 17:36:43 UTC
This appears to be a problem at my end, rather than with koha. Cancelling.
Comment 3 Chris Cormack 2012-06-26 01:30:03 UTC
Also in older mysql, it was TYPE=InnoDB, and in later ENGINE=InnoDB

Just in case that was the issue