The incorrect column specifier for column 'stuId' in the SQL statement is 'auto_increment'. The correct column specifier for auto-incrementing primary keys in MySQL is 'AUTO_INCREMENT'. The corrected SQL statement should be:

CREATE TABLE student ( stuId VARCHAR(20) PRIMARY KEY AUTO_INCREMENT, name VARCHAR(10), age INT, gender ENUM('男', '女', '未知') DEFAULT '未知' NOT NULL );

分析sqlcreate table student	stuId varchar20 primary key auto_increment name varchar10 age int gender enum男女未知 default 未知 not null; Incorrect column specifier for column stuId

原文地址: https://www.cveoy.top/t/topic/iB8P 著作权归作者所有。请勿转载和采集!

免费AI点我,无需注册和登录