I am trying to set up a Members Databas using phpMyAdmin but I keep getting an error. Here is the code followed by the returned error. Any advice would be most welcome.
CREATE TABLE `web47-members-3`.`members` (
`id` INT NOT NULL AUTO_INCREMENT ,
`first_name` VARCHAR( 25 ) NOT NULL DEFAULT '',
`last_name` VARCHAR( 25 ) NOT NULL DEFAULT '',
`email` VARCHAR( 50 ) NOT NULL DEFAULT '',
`username` VARCHAR( 25 ) NOT NULL DEFAULT '',
`password` VARCHAR( 25 ) NOT NULL DEFAULT '',
`activated` ENUM NOT NULL DEFAULT '0',
`date` TIMESTAMP NOT NULL DEFAULT '0000-00-00 00:00:00',
PRIMARY KEY ( `id` ) ,
UNIQUE (
`id` ,
`email` ,
`username`
)
) ENGINE = MYISAM ;
MySQL said: Documentation
#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'NOT NULL DEFAULT '0', `date` TIMESTAMP NOT NULL DEFAULT '0000-00-00 00:00:00', ' at line 1
Mike
CREATE TABLE `web47-members-3`.`members` (
`id` INT NOT NULL AUTO_INCREMENT ,
`first_name` VARCHAR( 25 ) NOT NULL DEFAULT '',
`last_name` VARCHAR( 25 ) NOT NULL DEFAULT '',
`email` VARCHAR( 50 ) NOT NULL DEFAULT '',
`username` VARCHAR( 25 ) NOT NULL DEFAULT '',
`password` VARCHAR( 25 ) NOT NULL DEFAULT '',
`activated` ENUM NOT NULL DEFAULT '0',
`date` TIMESTAMP NOT NULL DEFAULT '0000-00-00 00:00:00',
PRIMARY KEY ( `id` ) ,
UNIQUE (
`id` ,
`email` ,
`username`
)
) ENGINE = MYISAM ;
MySQL said: Documentation
#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'NOT NULL DEFAULT '0', `date` TIMESTAMP NOT NULL DEFAULT '0000-00-00 00:00:00', ' at line 1
Mike
