我收到一個MySQL數據轉儲,並試圖將數據插入一組臨時表。下表顯示了第一個表的創建語句。當我運行這個時,我收到錯誤:「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 ''temp_books'( 'ID'int(11 ) NOT NULL AUTO_INCREMENT, 'start'varchar(20 ) ' at line 1
」。我已經檢查了MySQL語法的文檔,但我沒有看到問題所在。創建表語法錯誤
CREATE TABLE 'temp_books' (
'ID' int(11) NOT NULL AUTO_INCREMENT,
'start' varchar(20) NOT NULL,
'customer_id' int(11) NOT NULL DEFAULT '0',
'total_num' int(11) NOT NULL,
'amount' double(5,2) NOT NULL DEFAULT '0.00',
'changed' timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
PRIMARY KEY ('ID'),
UNIQUE KEY 'start' ('start')
) ENGINE=MyISAM AUTO_INCREMENT=4853 DEFAULT CHARSET=latin1;
用MySQL允許一些如int(11)? – 2009-01-18 03:02:41