对于我的生活,我似乎可以搞清楚
INSERT INTO category SET CategoryName = 'Hardware_1',Category = 'HARDWARE',Status = '1',Order = '1'
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 'Order = '1'' at line 1
CREATE TABLE `category` (
`CategoryID` int(11) NOT NULL AUTO_INCREMENT,`CategoryName` varchar(255) NOT NULL,`Category` varchar(255) NOT NULL,`Status` tinyint(4) NOT NULL,`Order` int(11) NOT NULL,PRIMARY KEY (`CategoryID`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
最佳答案
订单是保留字.如果您打算使用它,请在反引号中附上订单.
原文链接:https://www.f2er.com/mysql/434257.htmlINSERT INTO category SET CategoryName = 'Hardware_1',`Order` = '1'