BamBamm Posted July 29, 2007 Share Posted July 29, 2007 I have MySQL version 4.1.22-standard-log installed and I tried to install a games script, but it gives me this error: MySQL said: #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 '+-------------+-----------------------------------------------------------------' at line 1 +-------------+-----------------------------------------------------------------------------+------+-----+---------------------+----------------+ | Field | Type | Null | Key | Default | Extra | +-------------+-----------------------------------------------------------------------------+------+-----+---------------------+----------------+ | gameID | smallint(6) | | PRI | NULL | auto_increment | | whitePlayer | mediumint(9) | | | 0 | | | blackPlayer | mediumint(9) | | | 0 | | | gameMessage | enum('playerInvited','inviteDeclined','draw','playerResigned','checkMate') | YES | | NULL | || messageFrom | enum('black','white') | YES | | NULL | | | dateCreated | datetime | | | 0000-00-00 00:00:00 | | | lastMove | datetime | | | 0000-00-00 00:00:00 | | +-------------+-----------------------------------------------------------------------------+------+-----+---------------------+----------------+ CREATE TABLE games ( gameID SMALLINT NOT NULL AUTO_INCREMENT PRIMARY KEY, whitePlayer MEDIUMINT NOT NULL, blackPlayer MEDIUMINT NOT NULL, gameMessage ENUM('playerInvited', 'inviteDeclined', 'draw', 'playerResigned', 'checkMate') NULL, messageFrom ENUM('black', 'white') NULL, dateCreated DATETIME NOT NULL, lastMove DATETIME NOT NULL ); Thanks for looking and for any help! Quote Link to comment Share on other sites More sharing options...
AndyB Posted July 29, 2007 Share Posted July 29, 2007 There's nothing wrong with the table creation query you quoted here. It works fine. Somehow your own query has gotten a whole bunch of +----- junk in it. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.