Invalid default value

marcus0263 - June 13, 2009 - 14:42
Project:Letters
Version:6.x-1.2
Component:Code
Category:bug report
Priority:critical
Assigned:Unassigned
Status:closed
Description

Attempting to activate this module and receive this error

user warning: Invalid default value for 'newsid' query: CREATE TABLE letters_newspapers ( `newsid` INT unsigned NOT NULL auto_increment DEFAULT 0, `title` VARCHAR(255) NOT NULL, `address` VARCHAR(255) DEFAULT NULL, `city` VARCHAR(255) DEFAULT NULL, `state` VARCHAR(2) DEFAULT NULL, `zip` VARCHAR(10) DEFAULT NULL, `phone` VARCHAR(15) DEFAULT NULL, `fax` VARCHAR(15) DEFAULT NULL, `email` VARCHAR(255) DEFAULT NULL, `homepage` VARCHAR(255) DEFAULT NULL, `statewide` INT unsigned NOT NULL DEFAULT 0, PRIMARY KEY (newsid), INDEX letters_zip (zip) ) /*!40100 DEFAULT CHARACTER SET UTF8 */ in /xxxxx/xxxxx/drupal-6.12/includes/database.inc on line 515.,
Drupal v6.12 multisite config

#1

marcus0263 - June 13, 2009 - 14:44

Additional info
When I uninstall I receive this -

user warning: Unknown table 'letters_newspapers' query: DROP TABLE letters_newspapers in /xxxx/xxxxx/drupal-6.12/includes/database.mysql-common.inc on line 261.

#2

seanr - June 22, 2009 - 20:32
Status:active» fixed

Please get the letters.install from CVS HEAD and try that. Looks like MySQL doesn't like a default value on an auto_increment field. Let me know if it works.

#3

System Message - July 6, 2009 - 20:40
Status:fixed» closed

Automatically closed -- issue fixed for 2 weeks with no activity.

 
 

Drupal is a registered trademark of Dries Buytaert.