麻煩看看為什么報(bào)錯(cuò)呢?
CREATE TABLE tdb_goods_brands(?
brand_id INT PRIMARY KEY AUTO_INCREMENT UNSIGNED, brand_name VARCHAR(40) NOT NULL?
)
SELECT brand_name FROM tdb_goods GROUP BY brand_name;
ERROR 1064 (42000): 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 'UNSIGNED, brand_name VARCHAR(40) NOT NULL ) SELECT brand_name FROM tdb_goods GRO' at line 1
2015-07-02
unsigned 書寫位置錯(cuò)誤了,應(yīng)該在寫數(shù)據(jù)類型的時(shí)候?qū)懺谒竺?!像這樣 ?int unsigned
2015-06-25
你創(chuàng)建的表名為'tdb_goods_brands',而你from的表卻是'tdb_goods'