試圖加載以下到數據庫Mysql的加載:錯誤使用phpMyAdmin
SET @[email protected]@UNIQUE_CHECKS, UNIQUE_CHECKS=0;
SET @[email protected]@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0;
SET @[email protected]@SQL_MODE, SQL_MODE='TRADITIONAL';
use es;
-- -----------------------------------------------------
-- Table `events`
-- -----------------------------------------------------
DROP TABLE IF EXISTS `events` ;
CREATE TABLE IF NOT EXISTS `events` (
`idEvent` INT NOT NULL AUTO_INCREMENT,
`type` VARCHAR(255) NULL ,
`name` VARCHAR(255) NULL ,
`city` VARCHAR(255) NULL ,
`state` VARCHAR(255) NULL ,
`location` VARCHAR(255) NULL ,
`shirtRequired` TINYINT(1) NULL COMMENT 'shirtRequired is a flag set by the Event Director to indicate if participants must purchase and/or wear an event shirt.' ,
`eventImage` BINARY NULL ,
`eventURL` VARCHAR(255) NULL ,
`date` DATE
PRIMARY KEY (`idEvent`))
;
我用mysql 5.1.36和使用的phpmyadmin WAMP。我收到以下錯誤:
#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 '(
idEvent
))' at line 12
我相信這是由使用保留字造成的。但我不確定。這個mysql來自一個轉儲,我寧願不改變它。我聽說過可編程模式,但不能發現太多。這會幫助我嗎?如果是這樣,我需要做什麼。
桑德Rijken感謝編輯後。我也想弄明白。 – Joe 2009-12-18 12:40:55