XS NOTNULL problem installing 1.0.8 ... and a solution
Posted: 13 Sep 2007, 07:59
I set up a brand new install of Mantis 1.0.8 on a Windows XP box running Xampp with PHP 5 and MySQL 5. I welcome the spiffy new MySQL installer, but it barfed when setting up the tables. The file mantis-1.0.8/admin/schema.php contains a bunch of commands that look like this:
When I tried installing, MySQL complained about "value XS NOTNULL". I tried installing this release on my trusty iBook with php 4 and MySQL 4. That worked perfectly, so I dumped the database and looked at the corresponding code:
So in the file schema.php on the Windows box I replaced every instance of "XS NOTNULL" with "text NOT NULL" and ran the installer again. This time it worked without a hitch.
(I haven't gone to the MySQL docs to see whether XS is a deprecated type definition that no longer works in v5 or something.)
Code: Select all
$upgrade[] = Array('CreateTableSQL',Array(config_get('mantis_config_table'),"
config_id C(64) NOTNULL PRIMARY,
project_id I DEFAULT '0' PRIMARY,
user_id I DEFAULT '0' PRIMARY,
access_reqd I DEFAULT '0',
type I DEFAULT '90',
value XS NOTNULL",
Code: Select all
CREATE TABLE `mantis_config_table` (
`config_id` varchar(64) NOT NULL default '',
`project_id` int(11) NOT NULL default '0',
`user_id` int(11) NOT NULL default '0',
`access_reqd` int(11) default '0',
`type` int(11) default '90',
`value` text NOT NULL,
PRIMARY KEY (`config_id`,`project_id`,`user_id`),
KEY `idx_config` (`config_id`)
) TYPE=MyISAM;
(I haven't gone to the MySQL docs to see whether XS is a deprecated type definition that no longer works in v5 or something.)