Install script fails with SQL error...

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Eric Holtman
    New Member
    • Oct 2005
    • 21
    • 3.0.9

    Install script fails with SQL error...

    I had some problems moving servers, so I decided to try a fresh install of 3.5.1 on my new server just to see what's what.

    Install fails with the following error:

    Database error in vBulletin :

    Invalid SQL:

    CREATE TABLE deletionlog (
    primaryid INT UNSIGNED NOT NULL DEFAULT '0',
    type ENUM('post', 'thread') DEFAULT 'post',
    userid INT UNSIGNED NOT NULL DEFAULT '0',
    username VARCHAR(100) NOT NULL DEFAULT '',
    reason VARCHAR(125) NOT NULL DEFAULT '',
    PRIMARY KEY (primaryid, type)
    );

    MySQL Error : All parts of a PRIMARY KEY must be NOT NULL; If you need NULL in a key, use UNIQUE instead
    Error Number : 1171
    Date : Sunday, January 1st 2006 @ 09:33:00 AM


    Sigh.

    When I look at the database backup I made of my old board (which is also 3.5.1), the deletionlog table is built like so:

    CREATE TABLE `deletionlog` (
    `primaryid` int(10) unsigned NOT NULL default '0',
    `type` enum('post','thread') NOT NULL default 'post',
    `userid` int(10) unsigned NOT NULL default '0',
    `username` varchar(100) NOT NULL default '',
    `reason` varchar(125) NOT NULL default '',
    PRIMARY KEY (`primaryid`,`type`)
    ) TYPE=MyISAM;


    so, 'type' is indeed "NOT NULL" there. Why is the install for 3.5.1 different?
  • Steve Machol
    Former Customer Support Manager
    • Jul 2000
    • 154488

    #2
    This error is from an outdated version of MySQL. Please see this bug for a fix to this problem with older versions of MySQL:

    Steve Machol, former vBulletin Customer Support Manager (and NOT retired!)
    Change CKEditor Colors to Match Style (for 4.1.4 and above)

    Steve Machol Photography


    Mankind is the only creature smart enough to know its own history, and dumb enough to ignore it.


    Comment

    widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
    Working...